下载 Json.Net DLL http://www.newtonsoft.com/json 需要翻墙
using Newtonsoft.Json; public string DataTableToJsonWithJsonNet(DataTable table) { string JsonString=string.Empty; JsonString = JsonConvert.SerializeObject(table); return JsonString;
或者在vs内部直接搜索Json安装, 需要翻墙