Powershell import-module webadministration
- by David
Every time I execute this command
invoke-command -computername REMOTEPC -scriptblock { import-module WebAdministration; new-item "$env:systemdrive\inetpub\testsite" -type directory; New-WebSite -Name TestSite -Port 81 -PhysicalPath "$env:systemdrive\inetpub\testsite" }
I get the following error
Invalid class string (Exception from HRESULT:…