Hey, I want to deactivate and then activate my wlan adapter via powershell. I already queried the Hardware-ID of the device. My script looks like this:
$wireless = Get-WmiObject win32_networkadapter | where {$_.DeviceId -eq 12}
$wireless.Disable()
Start-Sleep -s 1
$wireless.Enable()
read-host
But when run the script it throws no error. But the wlan-connection keeps established. I'm pretty shure its the right hardware-ID (i only have one device from intel, and that's my wireless lan device).
I already googled the problem, but couldn't solve it :-/ Happy for any help! Thanks! Tobi