With the code below I am monitoring the network name (windstream) which is the name of my wireless network.
It returns windstream until I open Devices and Printers and click Add Printer. While scanning for a new printer the network name changes to DIRECT-EIDESKTOP-V3D3LUJPHRW
I have no idea what (DIRECT-EIDESKTOP-V3D3LUJPHRW) is. DESKTOP-V3D3LUJ is my computer name.
This only happens on my PC running windows 10. I tried it on 2 other computers running windows 10 with no issues.
Why would scanning for a new printer cause the network name to change? Once the Add Printer dialog window is closed this script detects windstream again.
Code: Select all
loop
{
for INetwork in ComObjCreate("{DCB00C01-570F-4A9B-8D69-199FDBA5723B}").GetNetworks(1)
try ActiveNetwork := INetwork.GetName()
if ActiveNetwork <> windstream
MsgBox %activenetwork%
sleep 1000
}
escape::
exitapp