I wanted to use visual basic macro in excel to pull search results from Google. I used the following code (that I found from a tutorial) to connect to Google's search engine. I'm not very familiar with how visually basic macro works in excel. The following code actually works; however, I have problem with getting the search engine to output results for the correct region. Since I live in China right now, the macro is generating search results from Google which is not what I want. Is there a way to stop the redirection?
Const GOOGLE_WEBSERVER = "www.google.com" Function BuildSERPURL(ByVal term As String, ByVal start As Integer) As String BuildSERPURL = "http://" & GOOGLE_WEBSERVER & "/search?start=" & start & "&q=" & term End Function


Sign In
Create Account

Back to top









