< Back

Remove-ScheduledRestartComputerJob

Sat Jan 18, 2020 4:34 pm

NAME Remove-ScheduledRestartComputerJob



SYNOPSIS

Remove scheduled Restart-Computer job and script.





SYNTAX

Remove-ScheduledRestartComputerJob [-Name] <String> [[-JobNamePrefix] <String>] [[-ScriptFilePath] <String>]

[-WhatIf] [-Confirm] [<CommonParameters>]





DESCRIPTION

Remove scheduled Restart-Computer job and script.





PARAMETERS

-Name <String>

The full name of the scheduled restart computer job if known.



Required? true

Position? 1

Default value

Accept pipeline input? true (ByPropertyName)

Accept wildcard characters? false



-JobNamePrefix <String>

The prefix of the scheduled restart computer job exists to differentiate

the restart jobs from other PowerShell scheduled jobs.



Required? false

Position? 2

Default value RestartComputer-

Accept pipeline input? false

Accept wildcard characters? false



-ScriptFilePath <String>

The path to the script file that is executed by the scheduled restart computer

job.



Required? false

Position? 3

Default value C:\\Temp\\

Accept pipeline input? false

Accept wildcard characters? false



-WhatIf [<SwitchParameter>]



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Confirm [<SwitchParameter>]



Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS



NOTES





Created by: Jason Wasser @wasserja

Modified: 6/2/2017



-------------------------- EXAMPLE 1 --------------------------



PS C:\\>Remove-ScheduledRestartComputerJob













-------------------------- EXAMPLE 2 --------------------------



PS C:\\>Remove-ScheduledRestartComputerJob -Name MyJob -JobNamePrefix 'RestartComputerJob' -ScriptFilePath

'C:\\Scripts'



Requires -RunAsAdministrator

Requires -Modules PSScheduledJob











RELATED LINKS