Thanks, but this code detects the type of network adapter that is active, and I want to detect the type of network adapter what I select it.
example:
If you have two adapters (Wi-Fi and Ethernet), and Wi-Fi is active and the Ethernet is not active, and if I select Ethernet to get the result = Wireless80211.
or
if the active Ethernet and Wi-Fi is not active, and I select Wi-Fi as a result get = Ethernet.