Error: Only Object-type variables allowed in a "With" statement

Error: Only Object-type variables allowed in a "With" statement

107
Created On 11/10/26 10:56 AM - Last Modified 11/10/26 16:06 PM


Symptom


When launching Web Application Connection Components the following error is populated in a dialog box

Error: Only Object-type variables allowed in a "With" statement


Environment


10.0;10.1;10.2;10.3;10.4;10.5;10.6;10.7;10.8;10.9;10.10;11.1;11;11.2;11.3;11.4 PSM Connection Components

Cause


This is caused when the hardening PowerShell script is run with $SUPPORT_WEB_APPLICATIONS = $false

Resolution


Edit the PSMHardening.ps1 and set true for SUPPORT_WEB_APPLICATIONS located in CyberArk\PSM\Hardening\PSMHardening.ps1

Edit the following line: 
$SUPPORT_WEB_APPLICATIONS          = $true

Save and rerun the PSMHardening.ps1


Actions
  • Print
  • Copy Link

    https://knowledgebase.paloaltonetworks.com/KCSArticleDetail?id=kA1hj0000001MpiCAE&lang=en_US&refURL=http%3A%2F%2Fknowledgebase.paloaltonetworks.com%2FKCSArticleDetail