Alex Kouznetsov wrote:
> 
> I'd like to be able to check if a dial-up connection I want to establish
> (via RASDial) is already active.
> 
> Can anybody point me to some info and/or code samples on how to do this.

>From memory you have to use the API call RasEnumConnections.  It fills a
buffer with information about each active ras connection, giving you the
entry name, device type and name, etc.  You can then compare the entry name
to the one you want to dial.

If you just want to make sure you have a PPP connection - ie: if you don't
have any dial-up connections to non-internet servers - then there's a poorly
documented IOCTL you can use to get the properties of all the active network
connections.  Let me know if you want more info on that.

-- 
Corey Murtagh
The Electric Monk
"Quidquid latine dictum sit, altum viditur!"
---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED] 
with body of "unsubscribe delphi"

Reply via email to