Snakebitten
New Member
- Joined
- Apr 21, 2014
- Messages
- 3
Hi, I'm running a QueryTables.Add(Connection:="URL".. that generates a Google site: search.
It works fine on my laptop computer, generating the results I expect (the indexed URLs on a site). However, on my desktop, which is a faster machine, I am only generating this Google message:
Google Instant is unavailable. Press Enter to search. Learn more
Google Instant is off due to connection speed. Press Enter to search.
Press Enter to search.
How can I prevent this from happening?
In the code, ActiveCell.Offset(0, 0).Value = any domain name like "WWW.mydomain.com"
Here is the code:
___________________________________________________________________________________
'
Dim TheURL
Dim URL_Address
Dim URL_Sheet
TheURL = "http://www.google.com/search?q=site%3A"
TheURL = TheURL & ActiveCell.Offset(0, 0).Value
URL_Sheet = ActiveSheet.Name
URL_Address = ActiveCell.Address
Sheets("SiteLookup").Select
Range("A1").Select
ActiveCell.Select
With ActiveSheet.QueryTables.Add(Connection:= _
"URL;" & TheURL, Destination:=ActiveCell)
.Name = "q?s=glqry_1"
.FieldNames = True
.RowNumbers = False
.FillAdjacentFormulas = False
.PreserveFormatting = True
.RefreshOnFileOpen = False
.BackgroundQuery = False
.RefreshStyle = xlInsertDeleteCells
.SavePassword = False
.SaveData = True
.AdjustColumnWidth = True
.RefreshPeriod = 0
.WebSelectionType = xlAllTables
.WebFormatting = xlWebFormattingNone
.WebPreFormattedTextToColumns = True
.WebConsecutiveDelimitersAsOne = True
.WebSingleBlockTextImport = False
.WebDisableDateRecognition = False
.WebDisableRedirections = False
.Refresh BackgroundQuery:=False
End With
'
It works fine on my laptop computer, generating the results I expect (the indexed URLs on a site). However, on my desktop, which is a faster machine, I am only generating this Google message:
Google Instant is unavailable. Press Enter to search. Learn more
Google Instant is off due to connection speed. Press Enter to search.
Press Enter to search.
How can I prevent this from happening?
In the code, ActiveCell.Offset(0, 0).Value = any domain name like "WWW.mydomain.com"
Here is the code:
___________________________________________________________________________________
'
Dim TheURL
Dim URL_Address
Dim URL_Sheet
TheURL = "http://www.google.com/search?q=site%3A"
TheURL = TheURL & ActiveCell.Offset(0, 0).Value
URL_Sheet = ActiveSheet.Name
URL_Address = ActiveCell.Address
Sheets("SiteLookup").Select
Range("A1").Select
ActiveCell.Select
With ActiveSheet.QueryTables.Add(Connection:= _
"URL;" & TheURL, Destination:=ActiveCell)
.Name = "q?s=glqry_1"
.FieldNames = True
.RowNumbers = False
.FillAdjacentFormulas = False
.PreserveFormatting = True
.RefreshOnFileOpen = False
.BackgroundQuery = False
.RefreshStyle = xlInsertDeleteCells
.SavePassword = False
.SaveData = True
.AdjustColumnWidth = True
.RefreshPeriod = 0
.WebSelectionType = xlAllTables
.WebFormatting = xlWebFormattingNone
.WebPreFormattedTextToColumns = True
.WebConsecutiveDelimitersAsOne = True
.WebSingleBlockTextImport = False
.WebDisableDateRecognition = False
.WebDisableRedirections = False
.Refresh BackgroundQuery:=False
End With
'