Hi all, i am trying to call
$namespaceName = "root\cimv2\mdm\dmmap" $className = "MDM_RemoteWipe" $methodName = "doWipeMethod" $session = New-CimSession $params = New-Object Microsoft.Management.Infrastructure.CimMethodParametersCollection $param = [Microsoft.Management.Infrastructure.CimMethodParameter]::Create("param", "", "String", "In") $params.Add($param) $instance = Get-CimInstance -Namespace $namespaceName -ClassName $className -Filter "ParentID='./Vendor/MSFT' and InstanceID='RemoteWipe'" $session.InvokeMethod($namespaceName, $instance, $methodName, $params)
to Wipe a PC. However i still want the functionality to use Show-ADTInstallationPrompt via : $Response = Show-ADTInstallationPrompt -Message "Are you 100% sure you want to Wipe the Device? This will Delete EVERYTHING from the Device!" -ButtonRightText "Yes" -ButtonLeftText "No" -Title "Wipe the Device?"
Has anyone had this before? This will only go through if run as SYSTEM but i am afraid serviceUI.exe pushes itself in user context therefore running into permission issue again.
BR Niklas