ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Error Handling with Web Queries (https://www.excelbanter.com/excel-programming/318771-error-handling-web-queries.html)

Matt Lawson[_4_]

Error Handling with Web Queries
 
I have a program that collects data from web queries (the filename of the
webquery changes every hour, I use ontime on 5 minute intervals to always get
the newest data from the newest hour.)

Anyway, there's always a chance on the overlap that the new hour may not
have been generated yet. As such, occassionally the webquery will report:

"Connection was available but no data was there"

The problem with this is that it locks excel until someone clicks ok (ie the
timer will no longer run). Is there anyway I can disable the message from
appearing, or atleast not lock the program?

Using on error resume next or on error resume 0 in the procedure does not
seem to help.

Any ideas?

Thanks again

Matt Lawson

Bob Phillips[_6_]

Error Handling with Web Queries
 
Haven't tried it, but you could try adding Application.DisplayAlerts = False
to the code

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Matt Lawson" wrote in message
...
I have a program that collects data from web queries (the filename of the
webquery changes every hour, I use ontime on 5 minute intervals to always

get
the newest data from the newest hour.)

Anyway, there's always a chance on the overlap that the new hour may not
have been generated yet. As such, occassionally the webquery will report:

"Connection was available but no data was there"

The problem with this is that it locks excel until someone clicks ok (ie

the
timer will no longer run). Is there anyway I can disable the message from
appearing, or atleast not lock the program?

Using on error resume next or on error resume 0 in the procedure does not
seem to help.

Any ideas?

Thanks again

Matt Lawson




Matt Lawson[_4_]

Error Handling with Web Queries
 
I tried that, seems like a good idea.

However, it didn't seem to work.

if it helps, it's not a normal error message that pops up.

It's the office assistant with a triangular yellow sign with an excalamation
mark.


"Bob Phillips" wrote:

Haven't tried it, but you could try adding Application.DisplayAlerts = False
to the code

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Matt Lawson" wrote in message
...
I have a program that collects data from web queries (the filename of the
webquery changes every hour, I use ontime on 5 minute intervals to always

get
the newest data from the newest hour.)

Anyway, there's always a chance on the overlap that the new hour may not
have been generated yet. As such, occassionally the webquery will report:

"Connection was available but no data was there"

The problem with this is that it locks excel until someone clicks ok (ie

the
timer will no longer run). Is there anyway I can disable the message from
appearing, or atleast not lock the program?

Using on error resume next or on error resume 0 in the procedure does not
seem to help.

Any ideas?

Thanks again

Matt Lawson






All times are GMT +1. The time now is 08:04 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com