Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 493
Default web query with Workbooks.Open("http:// .....

I query a web page multiple times in a loop with a parameter to get different
pages. QueryTable does not get all the info I like. Furthermore, it does
not work unless one put in a delay in order for excel to wait for the result.


Found the OPEN method in a book; Workbooks.Open("http:// .....
This method is more robust, does not need a delay. I use .Find to parse
the page to get the data.
Just in case, I added a loop delay of about 10 seconds to avoid "issues"
related to server loading. However, eventually got message in the opened
excel book which indicates that the server stopped me. Once I got 100 hits
without problem. Last time I got 7 when the special message showed up for
the first time. Have not tested to see whether the server allows me again or
not.

Does the Workbooks.Open method behave different than a regular browser
click, apparently. Is there a method where one can download the entire web
page without looking different than a regular web access (from the server's
perspective)? I do not mind to have a long loop delay, e.g. 1 minute or more.

regards
Alex
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,588
Default web query with Workbooks.Open("http:// .....

What message did you get?
Typically web sites will not (understandably) like being "scraped" and may
put measures in place to prevent people accessing too many pages in quick
succession. These may apply both to browsers or to other tools such as
Excel.

Tim



"Alex" wrote in message
...
I query a web page multiple times in a loop with a parameter to get
different
pages. QueryTable does not get all the info I like. Furthermore, it does
not work unless one put in a delay in order for excel to wait for the
result.


Found the OPEN method in a book; Workbooks.Open("http:// .....
This method is more robust, does not need a delay. I use .Find to parse
the page to get the data.
Just in case, I added a loop delay of about 10 seconds to avoid "issues"
related to server loading. However, eventually got message in the opened
excel book which indicates that the server stopped me. Once I got 100
hits
without problem. Last time I got 7 when the special message showed up for
the first time. Have not tested to see whether the server allows me again
or
not.

Does the Workbooks.Open method behave different than a regular browser
click, apparently. Is there a method where one can download the entire
web
page without looking different than a regular web access (from the
server's
perspective)? I do not mind to have a long loop delay, e.g. 1 minute or
more.

regards
Alex



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 493
Default web query with Workbooks.Open("http:// .....

Hi Tim. thanks for your intrest

The message in the Workbook sheet that is opened as a result of the OPEN
method was something like; A message was sent to the IT dep.".

This is far from the exact message but the point is that they must have
understood that I accessed the web page in a different manner. I could use
the excel function; =HYPERLINK(CONCATENATE("http:// ... with a parameter for
the particular web page to get the web page in the browser automatically and
this would be undetectable that it comes under program control if I have a
sufficiently large loop delay (fixed + random) but then I do not know how to
access the browser text from EXCEL ..... I can only program EXCEL, never
done any html or browser programing

"Tim Williams" wrote:

What message did you get?
Typically web sites will not (understandably) like being "scraped" and may
put measures in place to prevent people accessing too many pages in quick
succession. These may apply both to browsers or to other tools such as
Excel.

Tim



"Alex" wrote in message
...
I query a web page multiple times in a loop with a parameter to get
different
pages. QueryTable does not get all the info I like. Furthermore, it does
not work unless one put in a delay in order for excel to wait for the
result.


Found the OPEN method in a book; Workbooks.Open("http:// .....
This method is more robust, does not need a delay. I use .Find to parse
the page to get the data.
Just in case, I added a loop delay of about 10 seconds to avoid "issues"
related to server loading. However, eventually got message in the opened
excel book which indicates that the server stopped me. Once I got 100
hits
without problem. Last time I got 7 when the special message showed up for
the first time. Have not tested to see whether the server allows me again
or
not.

Does the Workbooks.Open method behave different than a regular browser
click, apparently. Is there a method where one can download the entire
web
page without looking different than a regular web access (from the
server's
perspective)? I do not mind to have a long loop delay, e.g. 1 minute or
more.

regards
Alex




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Macro to copy from workbooks listed as http links Nick Smith[_2_] Excel Programming 8 April 29th 06 06:12 PM
Suppress "Disable/Enable Macros" and Query Refresh dialog on open Sharon Excel Programming 2 January 18th 06 09:20 PM
MSXML.DLL HTTP getAllResponseHeaders setRequestHeader "Cookie" Rick Excel Programming 0 October 25th 05 05:00 PM
VB Editor doesn't "recognize" open workbooks mikelee Excel Programming 1 August 20th 03 02:49 PM
Where can I find other arguments & desc to the Workbooks.open("myfile.xls") cmd? wellie Excel Programming 0 July 9th 03 11:32 PM


All times are GMT +1. The time now is 10:30 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"