Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Disabling error message with Web Query

Hi everyone,

I have developed an Excel Web Query that queries data from a web server and
put them into a database through VBA after refreshing. That query is running
in background and refreshes data every 30 minutes.
It happens the web server is not always available and the web query shows an
error message box ("Unalbe to http://webserver... Cannot locate the internet
server..."). The poblem is when this box appears the After_Refresh method not
execute as long as somebody clicks on the "OK" command button of the message
box.
Any idea to by pass this error message or making it not appear?

Regards,

--
Guilherme Soares
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,588
Default Disabling error message with Web Query

Try

Application.Displayalerts=False
'refresh query
Application.Displayalerts=True

--
Tim Williams
Palo Alto, CA


"Guilherme Soares" wrote in message
...
Hi everyone,

I have developed an Excel Web Query that queries data from a web server and
put them into a database through VBA after refreshing. That query is running
in background and refreshes data every 30 minutes.
It happens the web server is not always available and the web query shows an
error message box ("Unalbe to http://webserver... Cannot locate the internet
server..."). The poblem is when this box appears the After_Refresh method not
execute as long as somebody clicks on the "OK" command button of the message
box.
Any idea to by pass this error message or making it not appear?

Regards,

--
Guilherme Soares



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Disabling error message with Web Query

Tim, thanks for your response.
You're almost there. But, not worked properly because the Refresh method
from web query is not triggered by a macro. It's a process that runs in
background (do you know how we can deal with it?). This property only disable
alert messages coming from macro.
Any other idea?

--
Guilherme Soares


"Tim Williams" wrote:

Try

Application.Displayalerts=False
'refresh query
Application.Displayalerts=True

--
Tim Williams
Palo Alto, CA


"Guilherme Soares" wrote in message
...
Hi everyone,

I have developed an Excel Web Query that queries data from a web server and
put them into a database through VBA after refreshing. That query is running
in background and refreshes data every 30 minutes.
It happens the web server is not always available and the web query shows an
error message box ("Unalbe to http://webserver... Cannot locate the internet
server..."). The poblem is when this box appears the After_Refresh method not
execute as long as somebody clicks on the "OK" command button of the message
box.
Any idea to by pass this error message or making it not appear?

Regards,

--
Guilherme Soares




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,588
Default Disabling error message with Web Query

Have you tried using a mcro to refresh the query instead of having it run automatically ?
You could use Application.OnTime()

--
Tim Williams
Palo Alto, CA


"Guilherme Soares" wrote in message
...
Tim, thanks for your response.
You're almost there. But, not worked properly because the Refresh method
from web query is not triggered by a macro. It's a process that runs in
background (do you know how we can deal with it?). This property only disable
alert messages coming from macro.
Any other idea?

--
Guilherme Soares


"Tim Williams" wrote:

Try

Application.Displayalerts=False
'refresh query
Application.Displayalerts=True

--
Tim Williams
Palo Alto, CA


"Guilherme Soares" wrote in message
...
Hi everyone,

I have developed an Excel Web Query that queries data from a web server and
put them into a database through VBA after refreshing. That query is running
in background and refreshes data every 30 minutes.
It happens the web server is not always available and the web query shows an
error message box ("Unalbe to http://webserver... Cannot locate the internet
server..."). The poblem is when this box appears the After_Refresh method not
execute as long as somebody clicks on the "OK" command button of the message
box.
Any idea to by pass this error message or making it not appear?

Regards,

--
Guilherme Soares






  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Disabling error message with Web Query

How can I do that? How can I trigger the Refresh method from the query?

--
Guilherme Soares


"Tim Williams" wrote:

Have you tried using a mcro to refresh the query instead of having it run automatically ?
You could use Application.OnTime()

--
Tim Williams
Palo Alto, CA


"Guilherme Soares" wrote in message
...
Tim, thanks for your response.
You're almost there. But, not worked properly because the Refresh method
from web query is not triggered by a macro. It's a process that runs in
background (do you know how we can deal with it?). This property only disable
alert messages coming from macro.
Any other idea?

--
Guilherme Soares


"Tim Williams" wrote:

Try

Application.Displayalerts=False
'refresh query
Application.Displayalerts=True

--
Tim Williams
Palo Alto, CA


"Guilherme Soares" wrote in message
...
Hi everyone,

I have developed an Excel Web Query that queries data from a web server and
put them into a database through VBA after refreshing. That query is running
in background and refreshes data every 30 minutes.
It happens the web server is not always available and the web query shows an
error message box ("Unalbe to http://webserver... Cannot locate the internet
server..."). The poblem is when this box appears the After_Refresh method not
execute as long as somebody clicks on the "OK" command button of the message
box.
Any idea to by pass this error message or making it not appear?

Regards,

--
Guilherme Soares








  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,588
Default Disabling error message with Web Query

Create the query with automatic refresh tuned off, then use the Refresh
method to update it.

activesheet.querytables("tablename").refresh

I haven't tested that this doesn't still show the dialog though....

Tim


"Guilherme Soares" wrote in
message ...
How can I do that? How can I trigger the Refresh method from the query?

--
Guilherme Soares


"Tim Williams" wrote:

Have you tried using a mcro to refresh the query instead of having it run
automatically ?
You could use Application.OnTime()

--
Tim Williams
Palo Alto, CA


"Guilherme Soares" wrote in
message
...
Tim, thanks for your response.
You're almost there. But, not worked properly because the Refresh
method
from web query is not triggered by a macro. It's a process that runs in
background (do you know how we can deal with it?). This property only
disable
alert messages coming from macro.
Any other idea?

--
Guilherme Soares


"Tim Williams" wrote:

Try

Application.Displayalerts=False
'refresh query
Application.Displayalerts=True

--
Tim Williams
Palo Alto, CA


"Guilherme Soares" wrote
in message
...
Hi everyone,

I have developed an Excel Web Query that queries data from a web
server and
put them into a database through VBA after refreshing. That query
is running
in background and refreshes data every 30 minutes.
It happens the web server is not always available and the web query
shows an
error message box ("Unalbe to http://webserver... Cannot locate the
internet
server..."). The poblem is when this box appears the After_Refresh
method not
execute as long as somebody clicks on the "OK" command button of
the message
box.
Any idea to by pass this error message or making it not appear?

Regards,

--
Guilherme Soares








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
MS Query Error Message Mark Excel Programming 0 October 13th 06 12:07 PM
MS Query Error Message Mark Excel Programming 0 October 13th 06 12:06 PM
disabling a message box timmulla Excel Programming 10 July 25th 05 05:47 PM
error message in Microsoft Query - ORA-00903 invalid table name bert Excel Programming 2 October 28th 04 10:06 AM
Disabling the Update links message L Buchy Excel Programming 2 July 23rd 03 06:38 PM


All times are GMT +1. The time now is 06:36 PM.

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"