Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Closing an Internet connection
Message
 
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00687408
Message ID:
00695275
Views:
11
assign the return of the connection function to a varible
nConect = InternetAutodial (INTERNET_AUTODIAL_FORCE_ONLINE, 0)

to disconnect
InternetAutodialHangup(nConect)
>It's not clear from your message what the problem is. Can you elaborate?
>
>>The following code works as far as making a connection is concerned but does close the connection on my Win 2k Pro O/S.
>>
>>* Source: http://www.vb-world.net/tips/tip478.html
>>* Author: http://www.vb-world.net/php-bin/authorbio.php?
>>* authorid=3&associd=478&assoctype=3
>>
>>#DEFINE INTERNET_AUTODIAL_FORCE_ONLINE 1
>>#DEFINE INTERNET_AUTODIAL_FORCE_UNATTENDED 2
>>
>>DECLARE INTEGER InternetAutodial IN wininet.dll;
>> INTEGER dwFlags, INTEGER dwReserved
>>
>>DECLARE INTEGER InternetAutodialHangup IN wininet.dll;
>> INTEGER dwReserved
>>
>>* To prompt the user to connect to the Net
>>* InternetAutodial (INTERNET_AUTODIAL_FORCE_ONLINE, 0)
>>
>>* To automatically start dialling
>>* InternetAutodial (INTERNET_AUTODIAL_FORCE_UNATTENDED, 0)
>>
>>* To disconnect an automatically dialled connection
>>* InternetAutodialHangup(0)
>>
>>What alternatives are there, please?
>>
>>TIA
>>
>>Dennis
Previous
Reply
Map
View

Click here to load this message in the networking platform