MDM_RemoteWipe class

[Some information relates to pre-released product which may be substantially modified before it's commercially released. Microsoft makes no warranties, express or implied, with respect to the information provided here.]

The MDM_RemoteWipe class allows a remote wipe of a device.

The following syntax is simplified from Managed Object Format (MOF) code and includes all of the inherited properties.

Syntax

[InPartition("local-system"), dynamic, provider("DMWmiBridgeProv")]
class MDM_RemoteWipe
{
  string InstanceID;
  string ParentID;
};

Members

The MDM_RemoteWipe class has these types of members:

Methods

The MDM_RemoteWipe class has these methods.

Method Description
doWipeMethod Triggers the device to start the remote wipe.

Properties

The MDM_RemoteWipe class has these properties.

InstanceID

Data type: string

Access type: Read-only

Qualifiers: key

Identifies the name of the parent node. For this class, the string is "RemoteWipe".

ParentID

Data type: string

Access type: Read-only

Qualifiers: key

Describes the full path to the parent node. For this class, the string is "./Vendor/MSFT/"

Example

The following example demonstrates how to use the RemoteWipe and invoke the doWipeMethod.

Note

This example must be executed under local system user. To do that, download the psexec tool from https://technet.microsoft.com/sysinternals/bb897553.aspx and run psexec.exe -i -s cmd.exe from an elevated admin command prompt.

$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)

try
{
    $instance = Get-CimInstance -Namespace $namespaceName -ClassName $className -Filter "ParentID='./Vendor/MSFT' and InstanceID='RemoteWipe'"
    $session.InvokeMethod($namespaceName, $instance, $methodName, $params)
}
catch [Exception]
{
    write-host $_ | out-string
}

Requirements

Minimum supported client
Windows 10 [desktop apps only]
Minimum supported server
None supported
Namespace
Root\CIMv2\MDM\DMMap
MOF
DMWmiBridgeProv.mof
DLL
DMWmiBridgeProv.dll

See also

Using PowerShell scripting with the WMI Bridge Provider