i am getting json result from third party application for integration , it return the value as below. how i can get below json to dataset
{
"Return": {
"InvoiceDetails": {
"Invoiced": "20180930",
"InvoiceID": "",
"Amount": "0.00 "
}
Below is the c# code.
using (var streamInvoiceReader = new StreamReader(httpinvoiceResponse.GetResponseStream()))
{
var responseInv = streamInvoiceReader.ReadToEnd();
DataSet SetInvoice = JObject.Parse(responseInv)["InvoiceDetails"].ToObject<DataSet>();
if (SetInvoice != null && SetInvoice.Tables.Count > 0)
{
grvInvoice.DataSource = SetInvoice.Tables[0];
}
}
In responseInv i can see the return string and it is correct but not able to get it in dataset. there is any difference from result to return? How i can get the data from return array? thanks in advance.