Hi I have to parse json data into datatable object. Bellow is my json data
{
"Figurative Expressions (Idioms)" : {
"A" : [
{
"One word" : "Above all",
"Phrase" : "chiefly, before everything else"
},
{
"One word" : "Above-board",
"Phrase" : "not open to question, honest, straight-forward, beyond reproach"
},
{
"One word" : "Above-par",
"Phrase" : "of superior quality"
},
{
"One word" : "On account of ",
"Phrase" : "for the sake of"
},
{
"One word" : "On no account",
"Phrase" : "not for any reason"
},
{
"One word" : "To give a good account of oneself",
"Phrase" : "to act with credit to oneself"
}
]
}
}
How do we parse this json data in datatable?
As I tried with javascriptserializer, it was parsed successfully but didn't get anything in datatable.
JavaScriptSerializer js = new JavaScriptSerializer();
DataTable data1 = js.Deserialize<DataTable>(text);