Foxtable(狐表)用户栏目专家坐堂 → [求助]能帮我转成表格数据吗?


  共有3686人关注过本帖树形打印复制链接

主题:[求助]能帮我转成表格数据吗?

帅哥哟,离线,有人找我吗?
浙江仔
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:六尾狐 帖子:1326 积分:9609 威望:0 精华:1 注册:2010/7/21 14:20:00
[求助]能帮我转成表格数据吗?  发帖心情 Post By:2015/1/27 22:03:00 [只看该作者]

{"data": [{"contactTel":"","creditLevelCode":"","creditLevelName":"","entManageStateCode":"","entManageStateName":"","entScaleCode":"","entScaleName":"","enterpriseId":"1225c1a0b3384f29904ad9333c329395","enterpriseName":"湖州勤立防护设备有限公司","fcyhCount":0,"fcyhOver":0,"industryTypeCode":"","industryTypeName":"","isHaveMajorHazards":"","isUpScale":"","jdjcCount":0,"legalRepr":"","pareentId":"","pareentName":"","principalCode":"","principalMphone":"","principalName":"车火林","prodAddress":"","proddistCode":"330521104","proddistName":"钟管镇","qyzcCount":0,"regAddress":"","regAddressCode":"","regAddressName":"","regulatoryLevelCode":"E0905","regulatoryLevelName":"未定级","remark1":"","remark2":"","remark3":"","safetyDirectorCode":"","safetyDirectorMphone":"","safetyDirectorName":"","standLevelCode":"","standLevelName":"","zcYhCount":0,"zcyhNOChange":0,"zcyhOver":0},{"contactTel":"","creditLevelCode":"","creditLevelName":"","entManageStateCode":"","entManageStateName":"","entScaleCode":"","entScaleName":"","enterpriseId":"1ba2e50d0a8d42b3ab33043a13941f19","enterpriseName":"德清县思然纺织品有限公司","fcyhCount":0,"fcyhOver":0,"industryTypeCode":"","industryTypeName":"","isHaveMajorHazards":"","isUpScale":"","jdjcCount":0,"legalRepr":"","pareentId":"","pareentName":"","principalCode":"","principalMphone":"","principalName":"高永良","prodAddress":"","proddistCode":"330521113","proddistName":"禹越镇","qyzcCount":0,"regAddress":"","regAddressCode":"","regAddressName":"","regulatoryLevelCode":"E0905","regulatoryLevelName":"未定级","remark1":"","remark2":"","remark3":"","safetyDirectorCode":"","safetyDirectorMphone":"","safetyDirectorName":"","standLevelCode":"","standLevelName":"","zcYhCount":0,"zcyhNOChange":0,"zcyhOver":0}],"message":"successful","state":"1","total":2} 能帮忙把这数组转成表格数据么?

 回到顶部
帅哥哟,离线,有人找我吗?
有点甜
  2楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:版主 帖子:85326 积分:427815 威望:0 精华:5 注册:2012/10/18 22:13:00
  发帖心情 Post By:2015/1/27 22:19:00 [只看该作者]

 这些是json数据,要这样处理一下,类似,参考

 

http://foxtable.com/bbs/dispbbs.asp?BoardID=2&ID=25031&skin=0

 


 回到顶部
帅哥哟,离线,有人找我吗?
有点甜
  3楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:版主 帖子:85326 积分:427815 威望:0 精华:5 注册:2012/10/18 22:13:00
  发帖心情 Post By:2015/1/27 22:40:00 [只看该作者]

Dim json As String = FileSys.ReadAllText("d:\test.txt", Encoding.Default)
Dim ScriptControl As Object, data  As Object, JscriptCode As String
JscriptCode = "function toObject(json) {eval(""var o=""+json);return o;}"
ScriptControl = CreateObject("MSScriptControl.ScriptControl")
With ScriptControl
    .Language = "Javascript"
    .Timeout = -1
    .AddCode(JscriptCode)
    data = .Run("toObject", json)
End With

msgbox(data.message)

For Each o As object In data.data
    msgbox(o.enterpriseName)
Next


 回到顶部
帅哥哟,离线,有人找我吗?
浙江仔
  4楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:六尾狐 帖子:1326 积分:9609 威望:0 精华:1 注册:2010/7/21 14:20:00
  发帖心情 Post By:2015/1/28 21:55:00 [只看该作者]

谢谢甜哥,好用

 回到顶部