How can I read WAN and LAN connection status for specific network adapters, rather than having to rely on SysInfo's LAN_CONNECTIVITY and WAN_CONNECTIVITY types?
Long-winded explanation (sorry):
Hello. I have a network skin which handles a wide variety of network things, including monitoring specific network adapters. I have an icon in the top-left which shows the network status:
This icon is supposed to reflect the current network status. For example, if you are on ethernet but only connected to LAN, it will display a globe with an X in the corner:
(I'm probably going to change this one, but that's not the point).
Rainmeter's measures for detecting WAN and LAN connection status look like this:
Code: Select all
[MeasureConnectedLan] Measure=Plugin Plugin=SysInfo SysInfoType=LAN_CONNECTIVITY OnChangeAction=[!UpdateMeasure MeasureNetworkIcon][!Log "LAN State changed"] [MeasureConnectedWan] Measure=Plugin Plugin=SysInfo SysInfoType=INTERNET_CONNECTIVITY OnChangeAction=[!UpdateMeasure MeasureNetworkIcon][!Log "WAN State changed"]
My PC has several extra "network adapters": an Xbox wireless adapter, and a Hamachi server, among other things. The above measures consider these to be network adapters, so even if I completely unplug my PC's ethernet cord and the WiFi adapter, it will still think it's connected to a LAN.
What I wish for is a way to detect WAN and LAN connectivity status for individual adapters. So my skin could check the ethernet adapter's status, and if that isn't connected for some reason, check the WiFi adapter. If that also isn't connected, it could display "no internet".
Is this possible? Thanks in advance.