http://www.google.com/search?q=%E4%B8%AD%E5%9B%BD&btnG=Google%E6%90%9C%E7%B4%A2&hl=zh-CN&ie=UTF-8&oe=UTF-8
这个地址用浏览器看正常
用inet1.OpenURL(http://www.google.com/search?q=%E4%B8%AD%E5%9B%BD&btnG=Google%E6%90%9C%E7%B4%A2&hl=zh-CN&ie=UTF-8&oe=UTF-8) 返回的是一个403 Forbidden 页面
为什么,应该怎么弄,有解决办法吗???

解决方案 »

  1.   

    inet1.OpenURL(http://www.google.com/search?q=%E4%B8%AD%E5%9B%BD&btnG=Google%E6%90%9C%E7%B4%A2&hl=zh-CN&ie=UTF-8&oe=UTF-8,icByteArray)试试
      

  2.   

    好像是Google不允许这样访问,它认为你的inet1.openURL为非法浏览器,
    用一个隐藏的Webbrowser控件试试呀,不知道你具体要得到什么值?
      

  3.   

    webbrowser太慢了
    为什么google不允许这样的访问,它是怎么处理的,还有什么办法吗
      

  4.   

    google是怎么设置才能不让inet控件访问的 csdn没人知道吗
      

  5.   

    inet1.proxy 设置代理不能访问吗?
      

  6.   

    我收集的这个代码不错,测试不比INET差关键是: txtSource.Text = objDocument.documentElement.outerHTMLtexturl.text="http://www.google.com/search?q=%E7%8E%A9%E5%85%B7%E5%8E%82&ie=UTF-8&oe=UTF-8&hl=zh-CN&lr="至于他是怎么实现的,就是看useragent..很多的站点都可以设置成不让webzip telepro 访问,还有就是不让搜索引擎漫游的!就是加了个robots.txt 详细的我还不知道!====
    Option ExplicitPrivate Sub cmdExit_Click()
        If MsgBox("Are you sure?", vbYesNo, "Exiting the application") = vbYes Then
            Unload Me
        End If
    End SubPrivate Sub cmdGo_Click()
        Dim objLink As HTMLLinkElement
        Dim objMSHTML As New MSHTML.HTMLDocument
        Dim objDocument As MSHTML.HTMLDocument
        
        
        lblStatus.Caption = "Gettting document via HTTP"
        
        ' This function is only available with Internet Explorer 5
        
        Set objDocument = objMSHTML.createDocumentFromUrl(txtURL.Text, vbNullString)
        
        lblStatus.Caption = "Getting and parsing HTML document"
        
        ' Tricky, to make the function wait for the document to complete, usually
        ' the transfer is asynchronus. Note that this string might be different if
        ' you have another language than english for Internet Explorer on the
        ' machine where the code is executed.
        
        While objDocument.readyState <> "complete"
            DoEvents
        Wend
        
        lblStatus.Caption = "Document completed"
        
        ' Copying the source to the text box
        
        txtSource.Text = objDocument.documentElement.outerHTML
        
        DoEvents
        
        ' Copying the title of the page to the label
        
        lblTitle.Caption = "Title : " & objDocument.Title
        
        DoEvents
        
        lblStatus.Caption = "Extracting links"
        
        ' Processing the link collection of the HTMLDocument object
        
        For Each objLink In objDocument.links
            lstLinks.AddItem objLink
            lblStatus.Caption = "Extracted " & objLink
            DoEvents
        Next
        
        lblStatus.Caption = "Done"
        
        Beep
        
    End Sub