$remoteAccessPolicyAppliesToMPSRef = $wsmanConnectionObject.NewReference("AMT_RemoteAccessPolicyAppliesToMPS") # $mpServer is an EPR to the AMT_ManagementPresenceRemoteSAP object created by the 'Add a Management Presence Server' use case. $remoteAccessPolicyAppliesToMPSRef.AddSelector("ManagedElement",$mpServerRef) # Traverse to the AMT_RemoteAccessPolicyAppliesToMPS instances that are connected to the $mpServer. foreach($remoteAccessPolicyAppliesToMPSItem in $remoteAccessPolicyAppliesToMPSRef.Enumerate("http://schemas.dmtf.org/wbem/wsman/1/wsman/SelectorFilter", $null)) { $remoteAccessPolicyRuleRef = $remoteAccessPolicyAppliesToMPSItem.Object.GetProperty("PolicySet").Ref $remoteAccessPolicyRuleRef.Delete() }