Sign in to follow this  
Followers 0
McGod

INetCon.au3

5 posts in this topic

I was hunting for awhile and finally came across a cmd that would disconnect/connect internet.

It only works for broadband although the command has dialup access aswell(Cant test no dialup)

Posted Image

It has 4 Functions:

_INetConnect($Service, $Username, $Password)

Will connect the service

Return Values:

1=Connected

0=Bad User/Pass

-1=Other error(Have to research em)

_INetDisconnect($Service)

Will disconnect the service

Return Values:

1=Disconnected

0=Errored

_INetStatus($Service)

Will check the status of a service

Return Values:

1=Connected

0=Disconnected

_INetReconnect($Service, $Username, $Password)

Will disconnect and reconnect the internet.

Return Values:

1=Reconnected

0=Bad user/pass

Example Script:

#include <INetCon.au3>

If _INetStatus("Sympatico") = 0 Then
_INetConnect("Sympatico", "b1xxxxx", "xxxxx")
Else
_INetDisconnect("Sympatico")
EndIf

InetCon.au3

Hopefully it will help people.

Share this post


Link to post
Share on other sites



Thanks for sharing, nice script.

Share this post


Link to post
Share on other sites

Many thanx. Works like a charm with my Dial up connection.

To get your Dial up connection name (in this example its called Sympatico) do this:

Right click on your dial up desktop shortcut -> Properties -> Find target


My Projects:[list][*]Guide - ytube step by step tut for reading memory with autoitscript + samples[*]WinHide - tool to show hide windows, Skinned With GDI+[*]Virtualdub batch job list maker - Batch Process all files with same settings[*]Exp calc - Exp calculator for online games[*]Automated Microsoft SQL Server 2000 installer[*]Image sorter helper for IrfanView - 1 click opens img & move ur mouse to close opened img[/list]

Share this post


Link to post
Share on other sites

hey, is it possible to expand the functionality to pass actual dialup numbers instead of only user/pass?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0