PowerShell 2.0: One Cmdlet at a Time 9 Checkpoint-Computer

Continuing the series looking at new cmdlets available in PowerShell 2.0. This time we look at the Checkpoint-Computer cmdlet.

What can I do with it?

Create a system restore point on XP or Vista systems.

Example:

Create a system restore point called Pre-RegistryChange

Checkpoint-Computer -description “Pre-RegistryChange”

How could I have done this in PowerShell 1.0?

You could have used the SystemRestore WMI class and the CreateRestorePoint method

$SystemRestore = [wmiclass]"\\.\root\default:systemrestore" $SystemRestore.CreateRestorePoint(“Pre-RegistryChange”, 0, 100)

1000 things 1% better!