Skip to content

Cannot import setting from 1.9 in 1.21 #526

@KremserHans

Description

@KremserHans

Hi,
have a problem to import Highlights from 1.9 into 1.21. Try it with several versions, but no success.
Get this message:

SMDTowerLogexpert 2.json

Cannot deserialize the current JSON object (e.g. {"name":"value"}) into type 'System.Collections.Generic.List1[LogExpert.Core.Entities.HighlightGroup]' because the type requires a JSON array (e.g. [1,2,3]) to deserialize correctly. To fix this error either change the JSON to a JSON array (e.g. [1,2,3]) or change the deserialized type so that it is a normal .NET type (e.g. not a primitive type like integer, not a collection type like an array or List<T>) that can be deserialized from a JSON object. JsonObjectAttribute can also be added to the type to force it to deserialize from a JSON object. Path 'alwaysOnTop', line 2, position 18.\n\n JsonSerializationException at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateObject(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, Object existingValue) at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize(JsonReader reader, Type objectType, Boolean checkAdditionalContent) at Newtonsoft.Json.JsonSerializer.DeserializeInternal(JsonReader reader, Type objectType) at Newtonsoft.Json.JsonSerializer.Deserialize(JsonReader reader, Type objectType) at Newtonsoft.Json.JsonConvert.DeserializeObject(String value, Type type, JsonSerializerSettings settings) at Newtonsoft.Json.JsonConvert.DeserializeObject[T](String value, JsonSerializerSettings settings) at Newtonsoft.Json.JsonConvert.DeserializeObject[T](String value) at LogExpert.Configuration.ConfigManager.Import(List1 currentGroups, FileInfo fileInfo, ExportImportFlags flags)
at LogExpert.Configuration.ConfigManager.ImportHighlightSettings(FileInfo fileInfo, ExportImportFlags importFlags)
at LogExpert.Dialogs.HighlightDialog.OnBtnImportGroupClick(Object sender, EventArgs e)
at System.Windows.Forms.Button.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.Button.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(HWND hWnd, UInt32 msg, WPARAM wparam, LPARAM lparam)

Metadata

Metadata

Assignees

Labels

bugPesky little gritter, needs squashing

Type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions