vbscript to detect ALL APs signal strength

hi gurus,

I have been trying to code for a program which could actually detect all the signal strengths from the available APs. So far I have found a code which is in vbscript but it only works when the network adapter is connected to the AP, is there a possible way of detecting the signal strength of all APs?

<code>
set objSwbemServices = GetObject("winmgmts:\\.\root\wmi")

do while 1
set colInstances = objSwbemServices.ExecQuery _
("Select * From MSNdis_80211_ReceivedSignalStrength Where Active = True")

for each objInstance in colInstances
signal = objInstance.Ndis80211ReceivedSignalStrength & " hsdBm"
next

wscript.echo signal
wscript.sleep(1000)
loop

</code>
[762 byte] By [hsteo] at [2007-11-20 10:16:40]