Link to home
Start Free TrialLog in
Avatar of digitalwav
digitalwavFlag for United States of America

asked on

Programmatically Create RAS connection and dial it

I am working on an app that needs to create a predefined VPN/RAS connection and auto dial it.  I'm positive this can be done with API calls, but I have no idea how.

Any Delphi or VB examples would be much appreciated.
ASKER CERTIFIED SOLUTION
Avatar of JDSkinner
JDSkinner

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of CodedK
I dont know if this helps:

Establishing a Dial-Up Connection to the Internet
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wininet/wininet/establishing_a_dial_up_connection_to_the_internet.asp

Also you could try this.

implementation

{$R *.DFM}

function tapiRequestMakeCall(DestAddress, AppName,
 CalledParty, Comment: PChar): Longint; stdcall; external 'TAPI32.DLL';

procedure TForm1.Button1Click(Sender: TObject);
var
 PhoneNumber, AppName: array[0..255] of Char;
begin
 PhoneNumber := '1234567890';
 StrPCopy(AppName, Application.Title);
 tapiRequestMakeCall(PhoneNumber, AppName, '', '');
end;
Avatar of digitalwav

ASKER

My hero! RasX rocks!