I have a JSON that looks like this
var json = "{\"Month\":1,\"Year\":\"2016\",\"Col1\":\"\",\"Forecast\":2121.00,\"etc\":\"etc\"}";
When I tried to deserialize it and convert to datatable, 2121.00 became 2121 losing its decimals and thus resulting to making the type of the column into int.
How can I deserialize it by retaining its value so it will still retain its decimal datatype in the datatable?
btw I'm using the Newtonsoft JSon using this method..
public string DataTableToJSONWithJSONNet(DataTable table)
{
string JSONString = string.Empty;
JSONString = JsonConvert.SerializeObject(table);
return JSONString;
}