Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

CmdletProvider.Force Property

 

Updated: April 27, 2016

Applies To: Windows PowerShell

Gets a Boolean value that indicates whether the provider should do everything possible to perform an operation.

Namespace:   System.Management.Automation.Provider
Assembly:  System.Management.Automation (in System.Management.Automation.dll)

public SwitchParameter Force { get; }

Property Value

Type: System.Management.Automation.SwitchParameter

True indicates that the provider should do everything possible to perform an operation. False indicates that the provider should attempt the operation, but allow even simple errors to terminate the operation.

For example, if Force is true and the user tries to copy a file to a path that already exists and the destination is read-only, the provider should copy over the existing read-only file. If Force is false, the provider should not attempt to write over the file and should write an error instead.

For more information about providers, see Windows PowerShell Providers [ps].

Return to top

Community Additions

Show: