I have a json of this type (product category) =
part_types: { 29662101: "Щетка стеклоочистителя", 29834101: "Молдинг лобового стекла", 30177101: "Стекло заднее", 43326101: "Стекло лобовое", 43334101: "Стекло форточки", 43335101: "Стекло боковое опускное", 43336101: "Стекло кузова боковое (не опускное)" } I deserialize through Json.Net, indicating that we have a dynamic class ( dynamic data = JsonConvert.DeserializeObject(Out) )
How to display all categories of goods, despite the fact that I do not know in advance which objects I need?
I do not know what to insert there:
foreach (dynamic item in data.part_types) { checkedListBox1.Items.Add(item.НЕ ЗНАЮ ЧТО СЮДА ВСТАВИТЬ); } P / S I hope it will be clear :)