以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  网站收索  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=92334)

--  作者:yangwenghd
--  发布时间:2016/11/1 9:33:00
--  网站收索
Dim proc As new Process
proc.File = "http://www.qichacha.com/s?wd=" & Tables("企业档案").Current("企业_名称")
proc.Start
 能帮忙看看这个吗?为什么不能和百度那样被收索呢?
感谢 感谢 
http://www.qichacha.com/

--  作者:李孝春
--  发布时间:2016/11/1 10:02:00
--  回复:(yangwenghd)网站收索
 表达式有误吧!
MessageBox.Show("图片点击可在新窗口打开查看http://www.qichacha.com/s?wd=" & Tables("企业档案").Current("企业_名称") &”)
看看弹出来的是什么? 
[此贴子已经被作者于2016/11/1 10:04:37编辑过]

--  作者:有点蓝
--  发布时间:2016/11/1 10:04:00
--  
在网站首页点击查询看生成的url是怎么样的

Dim proc As new Process
proc.File = "http://qichacha.com/search?key=“ & Tables("企业档案").Current("企业_名称") & ”&index=0"
proc.Start

--  作者:yangwenghd
--  发布时间:2016/11/1 10:31:00
--  
url 是怎么生成的啊 没有 文字不能收索,有了文字复制后是以前模拟的网站 感谢 感谢 
--  作者:有点蓝
--  发布时间:2016/11/1 10:52:00
--  
没看懂你什么意思
--  作者:有点青
--  发布时间:2016/11/1 11:12:00
--  

 路径要进行一下编码

 

Dim str As String = "锤子科技"
Dim ScriptControl As Object, data  As Object, JscriptCode As String
JscriptCode = "function toUrl() {return encodeURI(\'" & str & "\')}"
ScriptControl = CreateObject("MSScriptControl.ScriptControl")
With ScriptControl
    .Language = "Javascript"
    .Timeout = -1
    .AddCode(JscriptCode)
    str = .Run("toUrl")
End With

 

Dim proc As new Process
proc.File = "http://qichacha.com/search?key=" & str & "&index=0"
proc.Start