Unable to find type [System.Web.HttpUtility] in PowerShell
You need to load the System.Web
assembly. Use the Add-Type
cmdlet like so,
PS C:\> [System.Web.HttpUtility]::UrlEncode("www.google.com")Unable to find type [System.Web.HttpUtility].PS C:\> Add-Type -AssemblyName System.WebPS C:\> [System.Web.HttpUtility]::UrlEncode("www.google.com")www.google.com