Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
nil nil is offline
external usenet poster
 
Posts: 1
Default dialog box displayed when internet connection unavailable

help! i am building a system which uses web queries to import data fro
the internet. when i open the file, and there is no internet connectio
(i am on dial up) i am bombarded with dialogs telling me the site wa
unavailable, is there any code which i can input into my auto_ope
which will disable these message boxes, i have already tried

application.displayalerts = false

and

application.autoresponse

but that is only available in excel 2000.

Has ANYONE got any suggestions out there???
thanks in advance

nilz

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default dialog box displayed when internet connection unavailable

Hi Nilzz

You can use code like this in your subroutine to avoid errors
if you are not online (only with dial up connections)

For checking other connections check out this website
http://www.mvps.org/vbnet/

Public Declare Function InternetGetConnectedState _
Lib "wininet.dll" (lpdwFlags As Long, _
ByVal dwReserved As Long) As Boolean
Function IsConnected() As Boolean
Dim Stat As Long
IsConnected = (InternetGetConnectedState(Stat, 0&) < 0)
End Function

Sub Test()
' Randy Birch
If IsConnected = True Then
MsgBox "Copy your code here"
Else
MsgBox "You can't use this subroutine because you are not online"
End If
End Sub


--
Regards Ron de Bruin
(Win XP Pro SP-1 XL2000-2003)
www.rondebruin.nl



"nil " wrote in message ...
help! i am building a system which uses web queries to import data from
the internet. when i open the file, and there is no internet connection
(i am on dial up) i am bombarded with dialogs telling me the site was
unavailable, is there any code which i can input into my auto_open
which will disable these message boxes, i have already tried

application.displayalerts = false

and

application.autoresponse

but that is only available in excel 2000.

Has ANYONE got any suggestions out there???
thanks in advance

nilzz


---
Message posted from http://www.ExcelForum.com/



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default dialog box displayed when internet connection unavailable

hmmm... i understand what to do, but wat is that winking smily supposed
to be? is it a ;- )?


---
Message posted from http://www.ExcelForum.com/

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
Internet connection stuenov Excel Discussion (Misc queries) 0 February 22nd 09 07:25 PM
Internet connection stuenov Excel Discussion (Misc queries) 0 February 18th 09 03:52 PM
internet connection process at exel start tim Biedermann Setting up and Configuration of Excel 1 October 14th 06 03:53 PM
msn stock updates quit working & no internet connection in excel K9CE Excel Discussion (Misc queries) 0 July 13th 06 04:36 PM
Format Cells dialog box unavailable KimC Excel Discussion (Misc queries) 0 February 22nd 06 03:45 PM


All times are GMT +1. The time now is 01:21 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"