ExcelHome技术论坛

 找回密码
 免费注册

QQ登录

只需一步,快速开始

快捷登录

搜索
EH技术汇-专业的职场技能充电站 妙哉!函数段子手趣味讲函数 Excel服务器-会Excel,做管理系统 效率神器,一键搞定繁琐工作
HR薪酬管理数字化实战 Excel 2021函数公式学习大典 Excel数据透视表实战秘技 打造核心竞争力的职场宝典
让更多数据处理,一键完成 数据工作者的案头书 免费直播课集锦 ExcelHome出品 - VBA代码宝免费下载
用ChatGPT与VBA一键搞定Excel WPS表格从入门到精通 Excel VBA经典代码实践指南
查看: 653|回复: 4

提取网页源码内容绘制成表格

[复制链接]

TA的精华主题

TA的得分主题

发表于 2020-9-24 21:23 | 显示全部楼层 |阅读模式
怎么提取下面网页中部分内容的字段  汇总成表格?
names字段      skuId字段     price字段     stock字段


  TShop.Setup(
                  {"valItemInfo":{"skuList":[
{"names":"34 黑色 ","pvs":"20549:147478970;1627207:28341","skuId":"4505153839497"},
{"names":"35 黑色 ","pvs":"20549:296172561;1627207:28341","skuId":"4319668156744"},
{"names":"36 黑色 ","pvs":"20549:59280855;1627207:28341","skuId":"4319668156745"},
{"names":"37 黑色 ","pvs":"20549:72380707;1627207:28341","skuId":"4319668156746"},
{"names":"38 黑色 ","pvs":"20549:103189693;1627207:28341","skuId":"4319668156747"},
{"names":"39 黑色 ","pvs":"20549:418624880;1627207:28341","skuId":"4319668156748"},
{"names":"40 黑色 ","pvs":"20549:229418985;1627207:28341","skuId":"4319668156749"},
{"names":"41 黑色 ","pvs":"20549:407396361;1627207:28341","skuId":"4319668156750"},
{"names":"42 黑色 ","pvs":"20549:473680452;1627207:28341","skuId":"4319668156751"},
{"names":"43 黑色 ","pvs":"20549:225078235;1627207:28341","skuId":"4319668156752"},
{"names":"44 黑色 ","pvs":"20549:64797379;1627207:28341","skuId":"4319668156753"},
{"names":"34 白色 ","pvs":"20549:147478970;1627207:28320","skuId":"4505153839495"},
{"names":"35 白色 ","pvs":"20549:296172561;1627207:28320","skuId":"4319668156754"},
{"names":"36 白色 ","pvs":"20549:59280855;1627207:28320","skuId":"4319668156755"},
{"names":"37 白色 ","pvs":"20549:72380707;1627207:28320","skuId":"4319668156756"},
{"names":"38 白色 ","pvs":"20549:103189693;1627207:28320","skuId":"4319668156757"},
{"names":"39 白色 ","pvs":"20549:418624880;1627207:28320","skuId":"4319668156758"},
{"names":"40 白色 ","pvs":"20549:229418985;1627207:28320","skuId":"4319668156759"},
{"names":"41 白色 ","pvs":"20549:407396361;1627207:28320","skuId":"4319668156760"},
{"names":"42 白色 ","pvs":"20549:473680452;1627207:28320","skuId":"4319668156761"},
{"names":"43 白色 ","pvs":"20549:225078235;1627207:28320","skuId":"4319668156762"},
{"names":"44 白色 ","pvs":"20549:64797379;1627207:28320","skuId":"4319668156763"},
{"names":"34 绿色 ","pvs":"20549:147478970;1627207:28335","skuId":"4505153839496"},
{"names":"35 绿色 ","pvs":"20549:296172561;1627207:28335","skuId":"4505153839500"},
{"names":"36 绿色 ","pvs":"20549:59280855;1627207:28335","skuId":"4505153839504"},
{"names":"37 绿色 ","pvs":"20549:72380707;1627207:28335","skuId":"4505153839506"},
{"names":"38 绿色 ","pvs":"20549:103189693;1627207:28335","skuId":"4505153839494"},
{"names":"39 绿色 ","pvs":"20549:418624880;1627207:28335","skuId":"4505153839502"},
{"names":"40 绿色 ","pvs":"20549:229418985;1627207:28335","skuId":"4505153839499"},
{"names":"41 绿色 ","pvs":"20549:407396361;1627207:28335","skuId":"4505153839501"},
{"names":"42 绿色 ","pvs":"20549:473680452;1627207:28335","skuId":"4505153839503"},
{"names":"43 绿色 ","pvs":"20549:225078235;1627207:28335","skuId":"4505153839498"},
{"names":"44 绿色 ","pvs":"20549:64797379;1627207:28335","skuId":"4505153839505"}]
,"defSelected":[],"skuMap":
{";20549:418624880;1627207:28335;":
{"priceCent":15800,"price":"158.00","stock":358,"skuId":"4505153839502"},";20549:64797379;1627207:28320;":{"priceCent":15800,"price":"158.00","stock":996,"skuId":"4319668156763"},";20549:72380707;1627207:28341;":{"priceCent":15800,"price":"158.00","stock":899,"skuId":"4319668156746"},";20549:418624880;1627207:28341;":{"priceCent":15800,"price":"158.00","stock":521,"skuId":"4319668156748"},";20549:407396361;1627207:28320;":{"priceCent":15800,"price":"158.00","stock":2443,"skuId":"4319668156760"},";20549:296172561;1627207:28341;":{"priceCent":15800,"price":"158.00","stock":943,"skuId":"4319668156744"},";20549:296172561;1627207:28335;":{"priceCent":15800,"price":"158.00","stock":998,"skuId":"4505153839500"},";20549:229418985;1627207:28341;":{"priceCent":15800,"price":"158.00","stock":499,"skuId":"4319668156749"},";20549:59280855;1627207:28320;":{"priceCent":15800,"price":"158.00","stock":995,"skuId":"4319668156755"},";20549:147478970;1627207:28320;":{"priceCent":15800,"price":"158.00","stock":871,"skuId":"4505153839495"},";20549:473680452;1627207:28341;":{"priceCent":15800,"price":"158.00","stock":319,"skuId":"4319668156751"},";20549:225078235;1627207:28320;":{"priceCent":15800,"price":"158.00","stock":426,"skuId":"4319668156762"},";20549:103189693;1627207:28335;":{"priceCent":15800,"price":"158.00","stock":384,"skuId":"4505153839494"},";20549:229418985;1627207:28335;":{"priceCent":15800,"price":"158.00","stock":980,"skuId":"4505153839499"},";20549:103189693;1627207:28341;":{"priceCent":15800,"price":"158.00","stock":876,"skuId":"4319668156747"},";20549:64797379;1627207:28341;":{"priceCent":15800,"price":"158.00","stock":848,"skuId":"4319668156753"},";20549:473680452;1627207:28335;":{"priceCent":15800,"price":"158.00","stock":0,"skuId":"4505153839503"},";20549:72380707;1627207:28335;":{"priceCent":15800,"price":"158.00","stock":390,"skuId":"4505153839506"},";20549:418624880;1627207:28320;":{"priceCent":15800,"price":"158.00","stock":2005,"skuId":"4319668156758"},";20549:64797379;1627207:28335;":{"priceCent":15800,"price":"158.00","stock":0,"skuId":"4505153839505"},";20549:296172561;1627207:28320;":{"priceCent":15800,"price":"158.00","stock":876,"skuId":"4319668156754"},";20549:407396361;1627207:28341;":{"priceCent":15800,"price":"158.00","stock":300,"skuId":"4319668156750"},";20549:407396361;1627207:28335;":{"priceCent":15800,"price":"158.00","stock":0,"skuId":"4505153839501"},";20549:147478970;1627207:28335;":{"priceCent":15800,"price":"158.00","stock":998,"skuId":"4505153839496"},";20549:59280855;1627207:28341;":{"priceCent":15800,"price":"158.00","stock":923,"skuId":"4319668156745"},";20549:147478970;1627207:28341;":{"priceCent":15800,"price":"158.00","stock":981,"skuId":"4505153839497"},";20549:229418985;1627207:28320;":{"priceCent":15800,"price":"158.00","stock":2381,"skuId":"4319668156759"},";20549:225078235;1627207:28341;":{"priceCent":15800,"price":"158.00","stock":606,"skuId":"4319668156752"},";20549:59280855;1627207:28335;":{"priceCent":15800,"price":"158.00","stock":996,"skuId":"4505153839504"},";20549:473680452;1627207:28320;":{"priceCent":15800,"price":"158.00","stock":1850,"skuId":"4319668156761"},";20549:72380707;1627207:28320;":{"priceCent":15800,"price":"158.00","stock":1901,"skuId":"4319668156756"},";20549:225078235;1627207:28335;":{"priceCent":15800,"price":"158.00","stock":0,"skuId":"4505153839498"},";20549:103189693;1627207:28320;":


TA的精华主题

TA的得分主题

发表于 2020-9-24 22:33 | 显示全部楼层
总得举个例子,要做什么效果出来?

TA的精华主题

TA的得分主题

发表于 2020-9-24 22:40 | 显示全部楼层
[广告] VBA代码宝 - VBA编程加强工具 · VBA代码随查随用  · 内置多项VBA编程加强工具       ★ 免费下载 ★      ★使用手册
本帖最后由 libo5563 于 2020-9-24 23:27 编辑

先用记事本把双引号改为+,再拷到pq里当一个文本处理,(最好能放到文本文件里,读取就简单多了),看要求好像只要上半部分,改列名,字段合并之类的,鼠标就可以搞定了吧
1.png
2.jpg

1.rar

22.75 KB, 下载次数: 1

TA的精华主题

TA的得分主题

发表于 2020-9-29 16:35 | 显示全部楼层
[广告] VBA代码宝 - VBA编程加强工具 · VBA代码随查随用  · 内置多项VBA编程加强工具       ★ 免费下载 ★      ★使用手册
本帖最后由 pbi12580 于 2020-9-29 16:40 编辑

发帖原文的数据不全部,这是应该是一个完整 json ,获取数据里面选择 json,然后展开即可;
保留需要的项,删除不需要的列。 image.jpg

TA的精华主题

TA的得分主题

发表于 2020-10-31 17:41 | 显示全部楼层
下载的应该为Json文件改的Txt吧,要是复杂的Json文件,直接用Json文件导入
您需要登录后才可以回帖 登录 | 免费注册

本版积分规则

手机版|关于我们|联系我们|ExcelHome

GMT+8, 2024-11-15 16:33 , Processed in 0.041499 second(s), 12 queries , Gzip On, MemCache On.

Powered by Discuz! X3.4

© 1999-2023 Wooffice Inc.

沪公网安备 31011702000001号 沪ICP备11019229号-2

本论坛言论纯属发表者个人意见,任何违反国家相关法律的言论,本站将协助国家相关部门追究发言者责任!     本站特聘法律顾问:李志群律师

快速回复 返回顶部 返回列表