PowerShell icon indicating copy to clipboard operation
PowerShell copied to clipboard

Found some error when run this powershell

Open lucaswong opened this issue 6 years ago • 1 comments

NIC: Intel(R) Ethernet Connection (7) I219-V Allow the computer to turn off this device.....Success Allow this device to wake the computer.....Success Only allow a magic packet to wake the computer.....Success NIC: TAP-Windows Adapter V9

Allow the computer to turn off this device.....The property 'Enable' cannot be found on this object. Verify that the property exists and can be set.
At line:160 char:4
+             $NICPowerManage.Enable = $TurnOffDevice
+             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : PropertyNotFound
 
Method invocation failed because [System.Management.Automation.PSInternalMemberSet] does not contain a method named 'Put'.
At line:161 char:4
+             $HideOutput = $NICPowerManage.psbase.Put()
+             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (Put:String) [], RuntimeException
    + FullyQualifiedErrorId : MethodNotFound

Failed

Allow this device to wake the computer.....The property 'Enable' cannot be found on this object. Verify that the property exists and can be set.
At line:173 char:4
+             $NICPowerManage.Enable = $WakeComputer
+             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : PropertyNotFound
 
Method invocation failed because [System.Management.Automation.PSInternalMemberSet] does not contain a method named 'Put'.
At line:174 char:4
+             $HideOutput = $NICPowerManage.psbase.Put()
+             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (Put:String) [], RuntimeException
    + FullyQualifiedErrorId : MethodNotFound

Failed

Only allow a magic packet to wake the computer.....The property 'EnableWakeOnMagicPacketOnly' cannot be found on this object. Verify that the property exists and can be set.
At line:186 char:4
+             $NICPowerManage.EnableWakeOnMagicPacketOnly = $AllowMagic ...
+             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : PropertyNotFound
 
Method invocation failed because [System.Management.Automation.PSInternalMemberSet] does not contain a method named 'Put'.
At line:187 char:4

+             $HideOutput = $NICPowerManage.psbase.Put()

+             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo          : InvalidOperation: (Put:String) [], RuntimeException
+ FullyQualifiedErrorId : MethodNotFound

Failed

lucaswong avatar Oct 04 '19 07:10 lucaswong

This may be caused by the NIC you have and/or computer manufacture. We are using Dell systems that this works on.

mickpletcher avatar May 01 '20 14:05 mickpletcher