How to get a list of network connections using Delphi 7?

If you search through the registry, then there are ALL connections (including remote or only remote, xs, not really looked).

I need to get a list of active connections, such as, "Local Area Connection * 2", "Ethernet", etc.

  • 2
    all connections are made via WMI, from delphi you can wield with WMI - kandellak
  • one
  • @ user212880 Could you explain what is there for the archive by reference? - Nick Volynkin

2 answers 2

The most working and adequate option gave @ user212880 (it’s a pity that you didn’t issue your version as an answer, so you would get a plus =))

In the link, this user dropped an example of a working program, which (by some magic method for me) bypasses the entire list of network connections and even gives detailed information about each of them.

    There are two main options:

    1. WMI
    2. IP Helper API

    In particular, for WMI you need to select from the Win32_NetworkAdapter , and for the IP Helper, use GetAdaptersInfo .

    The Rouse_ example uses just IP Helper.