- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm working on a script to change the Wake on lan settings for a nic. I've loaded the intel proset software and able to read the values for wol. In the vbs script below. I'm having problems calling the SetWakeOnLanPowerOptions. Could someone take a quick look and let me know howto fix.
Joe--
'ON error resume next
strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "\\" & strComputer & "\root\IntelNCS2")
Set colItems = objWMIService.ExecQuery _
("Select * from IANet_PhysicalEthernetAdapter")
For Each objItem in colItems
'** This call in the program gets the wol properties **
output = objItem.GetWakeOnLanPowerOptions( WakeOnMagicePacketFromPowerOff, WakeOnLink , WakeOnMagicPacket, WakeOnDirectedPacket)
Wscript.echo "Wake Machine from Poweroff State" & WakeOnMagicePacketFromPowerOff
Wscript.echo "Wake the machine when Link is Present " & WakeOnLink
Wscript.echo "Wake the machine on Magic Packet " & WakeOnMagicPacket
Wscript.echo "Wake the machine on Directected Packet " & WakeOnDirectedPacket
'** This call is trying to set all options on **
output = objItem.SetWakeOnLanPowerOptions( 1 , 1 , 1 , 1, 1)
Next
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Did you by chance figure this out?
All I could determine from your script is that WakeOnMagicePacketFromPowerOff is not capturing a value of any kind; it is coming back NULL\BLANK on your ECHO tests (on the machine I am testing on).

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page