以文本方式查看主题 - Foxtable(狐表) (http://foxtable.com/bbs/index.asp) -- 专家坐堂 (http://foxtable.com/bbs/list.asp?boardid=2) ---- 如何把JSON保存网页 (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=188974) |
-- 作者:yifan3429 -- 发布时间:2023/11/2 21:31:00 -- 如何把JSON保存网页 Select Case e.Path Case "index.html" Dim dt As DataTable = DataTables("产品库_固装家具") Dim s As String = JsonConvert.SerializeObject(dt.BaseTable) Dim ja As JArray = JArray.Parse(s) For Each jo As JObject In ja jo.Remove("System_Sort_Temporary") jo.Remove("System_Filter_Temporary") jo.Remove("System_Filter_Unique") Next Dim js As String = CompressJson(ja.ToString) e.WriteString(js) e.Save("E:\\ww\\index.html") 我需要给layui使用数据 End Select
[此贴子已经被作者于2023/11/2 21:37:14编辑过]
|
-- 作者:有点蓝 -- 发布时间:2023/11/2 21:46:00 -- FileSys.WriteAllText("E:\\ww\\index.html", js, False, Encoding.UTF8) |