Detect active network adapter programmatically

  • Thread starter Thread starter keith
  • Start date Start date
K

keith

I have clients with laptops. At any given moment they
may be connected to the network via a wireless adapter,
via dial-ip, via ethernet, or not connected at all.

I need to be able to determine, programatically, if the
client currently has an ethernet connection.

I am sure there is an API that exposes this. In fact, i
have had some limited success with api's that enumerate
the adapters. The problem is, I can't seem to find any
way to determine which connection is actually being USED.

So - I don't care whether the solution uses an API or
not. I could just use some help coming up with a
creative solution to this dilemma.

Thanks for any suggestions!

Keith
 
Wow. That does EXACTLY what I wanted to do.

I won't embarass myself by confessing how much time i
spent trying to figure this one out.

But the solution you pointed me to works right out of the
box. Thanks very much for the quick reply!

Keith
 
Back
Top