Remove-SCSMWorkflow
Removes a workflow from Service Manager.
Syntax
Default (Default)
Remove-SCSMWorkflow
[-Workflow] <Workflow[]>
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Remove-SCSMWorkflow cmdlet removes a workflow from Service Manager.
Examples
Example 1: Remove a workflow
PS C:\>Get-SCSMWorkflow -Name "Incident02" | Remove-SCSMWorkflow
This command gets the workflow named Incident02 by using the Get-SCSMWorkflow cmdlet. The command passes that object to the current cmdlet by using the pipeline operator. That cmdlet deletes that workflow.
Parameters
-Confirm
Prompts you for confirmation before running the cmdlet.
Parameter properties
| Type: | System.Management.Automation.SwitchParameter |
| Default value: | False |
| Supports wildcards: | False |
| DontShow: | False |
| Aliases: | cf |
Parameter sets
(All)
| Position: | Named |
| Mandatory: | False |
| Value from pipeline: | False |
| Value from pipeline by property name: | False |
| Value from remaining arguments: | False |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Parameter properties
| Type: | System.Management.Automation.SwitchParameter |
| Default value: | False |
| Supports wildcards: | False |
| DontShow: | False |
| Aliases: | wi |
Parameter sets
(All)
| Position: | Named |
| Mandatory: | False |
| Value from pipeline: | False |
| Value from pipeline by property name: | False |
| Value from remaining arguments: | False |
-Workflow
Specifies an object that represents the workflow to remove.
Parameter properties
| Type: | Microsoft.EnterpriseManagement.ServiceManager.Sdk.Workflows.Workflow[] |
| Default value: | None |
| Supports wildcards: | False |
| DontShow: | False |
Parameter sets
(All)
| Position: | 0 |
| Mandatory: | True |
| Value from pipeline: | True |
| Value from pipeline by property name: | False |
| Value from remaining arguments: | False |
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
Inputs
Microsoft.EnterpriseManagement.ServiceManager.Sdk.Workflows.Workflow
You can pipe a workflow to the Workflow parameter.
Outputs
None.
This cmdlet does not generate any output.