Interesting Json format

  • Автор темы Автор темы myndeswx
  • Дата начала Дата начала

myndeswx

Client
Регистрация
15.05.2017
Сообщения
437
Реакции
104
Баллы
43
Hello, came across this unusual JSON format, thinking how to solve it ))
Maybe someone has any tips?
For example, we would want to parse the .type for all fields
Thank you
88559
 
Create user class for JSON object.
After that use JsonConvert.Desserialize to convert json string to c# object
 
  • Спасибо
Реакции: myndeswx
something like this should work for you. for example
C#:
Развернуть Свернуть Копировать
foreach(string name in project.Json.data.GetMembersList()){
    project.Tables["table1"].AddRow(new string[]{name, project.Json.data.GetMember(name)[0].type});
}
just use it after parsing json and replace 'table1' with your's table name is added in project.
 
Последнее редактирование:
  • Спасибо
Реакции: myndeswx, ZSHab и nicanil

Кто просматривает тему: (Всего: 0, Пользователи: 0, Гости: 0)