Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

c# json foreach key value

var dict = JObject.Parse(@"{""1"":""Name 1"",""2"":""Name 2""}");

var dict = JsonConvert.DeserializeObject<Dictionary<string, string>>(json);
foreach(var kv in dict)
{
    Console.WriteLine(kv.Key + ":" + kv.Value);
}
Comment

PREVIOUS NEXT
Code Example
Javascript :: MongoServerSelectionError: connect ECONNREFUSED ::1:27017 
Javascript :: array reduce and count based on proeperty js 
Javascript :: localstorage setitem javascript 
Javascript :: javascript tofixed only if decimal 
Javascript :: javascript calculate days between dates 
Javascript :: yarn react-bootstrap 
Javascript :: canvas change line color 
Javascript :: set default terminal vscode windows 
Javascript :: next js install swr 
Javascript :: is java and javascript a good combo 
Javascript :: how to close modal using esc key in nuxt js 
Javascript :: event on input or keydown or on paste value or on change jquery 
Javascript :: react post request 
Javascript :: convert hsl to hex code javascript 
Javascript :: js loop through object 
Javascript :: truthy or falsy value javascript 
Javascript :: get array length in jquery 
Javascript :: how map on object in javascrtipt 
Javascript :: js date locale brasil 
Javascript :: stampare una variabile in javascript 
Javascript :: generate random int js 
Javascript :: Codewars Square(n) Sum 
Javascript :: JavaScript check all checkboxes on page 
Javascript :: how to convert time to am pm in javascript 
Javascript :: stuck at "resolving packages" 
Javascript :: add comma to number in javascript 
Javascript :: ngcc failed angular 9 
Javascript :: regex to extract a phone number with country code 
Javascript :: react native nested screens 
Javascript :: expo build 
ADD CONTENT
Topic
Content
Source link
Name
2+7 =