I am following the Chocolately Install steps (Windows 7), but have run into a couple of problems.
Firstly, I've opened Command Prompt (opening it with Run as administrator), but when trying to execute Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
, I get this error:
Uncaught SyntaxError: Unexpected identifier
..with the https:
part of my command highlighted.
Further, when I try to execute Get-ExecutionPolicy
, it results in:
Uncaught ReferenceError: Get is not defined
Any ideas what could be wrong?
* UPDATE *
When I try the same command in PowerShell, I get this error:
PS C:\Users\mylogin> Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtoc ol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString ('https://chocolatey.org/install.ps1')) Exception setting "SecurityProtocol": "Cannot convert value "3312" to type "System.Net.SecurityProtocolType" due to inv alid enumeration values. Specify one of the following enumeration values and try again. The possible enumeration values are "Ssl3, Tls"." At line:1 char:85 + Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]:: <<<< SecurityProtocol = [System. Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://ch ocolatey.org/install.ps1')) + CategoryInfo : InvalidOperation: (:) [], RuntimeException + FullyQualifiedErrorId : PropertyAssignmentException
Exception calling "DownloadString" with "1" argument(s): "The underlying connection was closed: An unexpected error occ urred on a send." At line:1 char:219 + Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.Se rvicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString <<<< ('https://ch ocolatey.org/install.ps1')) + CategoryInfo : NotSpecified: (:) [], MethodInvocationException + FullyQualifiedErrorId : DotNetMethodException