I have a DataTable which has only a single row and looks like
America | Africa | Japan |
----------
As an alternative to the answer found here, you can use an ExpandoObject to quickly and pretty easily render a single row as JSON, as such:
var expando = new System.Dynamic.ExpandoObject() as IDictionary;
foreach (DataColumn col in myRow.Table.Columns)
{
eo[col.ColumnName] = myRow[col];
}
var json = JsonConvert.SerializeObject(expando);