Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Check DUN status
Message
From
14/10/1998 13:48:51
 
 
To
14/10/1998 11:28:26
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00146676
Message ID:
00146757
Views:
24
>Hello, does and body know a function in a DLL that can check if DialUp networking is intiated or not?

I've used InternetGetConnectedState(), but the results have not been consistent, and Rick Strahl reports that the wrapper is flakey. You can experiment with it, though - the API prototype is:
DECLARE SHORT InternetGetConnectedState IN WININet.DLL ;
    INTEGER @lpdwFlags, ;
    INTEGER dwReserved
nFlags = 0
nResult = InternetGetConnectedState(@nFlags, 0)
returns 1 on success, 0 if failed, and you need to check the flag values returned in the parameter nFlags using the values in WININET.H; 1 indicates a modem connection, 2 a LAN connection, 4 a proxy server connection, 8 modem in use busy, and zero means no connection exists. I've gotten incorrect results when DUN was trying to establish a link; it reported a connection even though it was in the process of dialing.
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform