Skip to content

Instantly share code, notes, and snippets.

@yuta-imai
Created December 3, 2016 07:27
Show Gist options
  • Save yuta-imai/a09bf19c7ca68993c3cf17af218439ab to your computer and use it in GitHub Desktop.
Save yuta-imai/a09bf19c7ca68993c3cf17af218439ab to your computer and use it in GitHub Desktop.
if (& Get-WMIObject win32_potsmodem){ C:\Windows\System32\rasphone.exe -d USBDEVICE }
@yuta-imai
Copy link
Author

You can run this script when LogON with Windows TaskScheduler.
Note You have to allow your system to execute script by issuing the command: Set-ExecutionPolicy RemoteSigned prior to do this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment