I'm newbie in asp.net c# . Iwant to show the json data into table with gridview .I have json data with this format :
[{
"reviewerID": "A1YS9MDZP93857",
"asin": "0006428320",
"reviewerName": "John Taylor",
"helpful": [
0,
0
],
"reviewText": "last movement of sonata #6 is missing. What should one expect?",
"overall": 3,
"summary": "Parts missing",
"unixReviewTime": 1394496000,
"reviewTime": "03 11, 2014"
},
{
"reviewerID": "A3TS466QBAWB9D",
"asin": "0014072149",
"reviewerName": "Silver Pencil",
"helpful": [
0,
0
],
"reviewText": "If you are a serious violin student on a budget, this edition has it all",
"overall": 5,
"summary": "Perform it with a friend, today!",
"unixReviewTime": 1370476800,
"reviewTime": "06 6, 2013"
}]
to show that into gridview I use the following code (using Json.net library)
JsonString = TextBox1.Text;
dt = (DataTable)JsonConvert.DeserializeObject(JsonString, (typeof(DataTable)));
GridView1.DataSource = dt;
GridView1.DataBind();
the problem is gridview cannot show the data, and it's work if I remove "helpfull" attribute like this one by one :
{
"reviewerID": "A1YS9MDZP93857",
"asin": "0006428320",
"reviewerName": "John Taylor",
"reviewText": "The portfolio is fine except for the fact that the last movement of sonata #6 is missing. What should one expect?",
"overall": 3,
"summary": "Parts missing",
"unixReviewTime": 1394496000,
"reviewTime": "03 11, 2014"}
I don't know code how to remove it , Since i have large json data, i'ts difficult and wasting time to remove it manually. Any idea?