Checking for connection to internet.

Fuga

Registered User.
Local time
Today, 19:45
Joined
Feb 28, 2002
Messages
566
Hi,

Is there a way to use VBA to check what connection you are currently using?

Based on this informationk, I´d like to change the profile in Ms Outlook (see my other post today) so that if you´re on a modem, the emails would come from "modem@sweden.se" and if you´re on DSL, it would be "DSL@sweden.se".

If I need to do API, I must warn you that I´m not very good at it.

I have done some VBA automating in Ms Outlook, however I can´t find what I´m looking for in the help file.

Thanks.

Fuga.
 
I found some Visual Basic code @ http://www.mvps.org/vbnet/index.html.

Search that site for the key words "active internet connection".

You will be interested in the "InternetGetConnectedState: Determine Network Connection Type" code.

Sorry for not posting the code but it is against that sites rules to post their code.
 

Users who are viewing this thread

Back
Top Bottom