wifi and girder question

Speak your mind

Postby DCulver on Wed Jan 03, 2007 7:48 pm

I eliminated the message box in the script. Here is the streamlined script:
Code: Select all
On Error Resume Next

strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")

regValueDataMetric = "35"

ConnectionStatus=7

Do while ConnectionStatus <> 2
   
   Set colItems = objWMIService.ExecQuery _
   ("Select * From Win32_NetworkAdapter Where NetConnectionID = 'Wireless Network Connection'")

   if colItems.count = 0 then
      msgbox "No Wireless Adapter Present!"
      ConnectionStatus=2
   else begin
      For Each objItem in colItems

         If objItem.NetConnectionStatus = 2 then
            Set GirderEvent = CreateObject("GirderX.Girder")
       call GirderEvent.TriggerEvent("CloseOverlay", 18, "", "", "", 0)
            ConnectionStatus=2
         
         End if
      Next
   end if

WScript.Sleep 1000

loop


This site won't let me send a PM, and I don't know how to or if I can post a file, so if you get me an email address, I'll send you the gml.
DCulver
 
Posts: 13
Joined: Sat Aug 02, 2003 3:51 pm
Location: Reno, NV

Postby capecodscot on Wed Jan 03, 2007 8:28 pm

Thanks very much for your help. I can be e-mailed at mailto:capecodscot@gmail.com.

Thanks once again for your assistance - I'll let you know how I get on.

T
capecodscot
 
Posts: 81
Joined: Sun Dec 04, 2005 11:21 pm
Location: MA, USA

Previous