New-CommanderSchedule
SYNOPSIS
Creates a scheduled action based on a CRON expression.
SYNTAX
New-CommanderSchedule [[-Action] <ScriptBlock>] [[-CronExpression] <String>] [<CommonParameters>]
DESCRIPTION
Creates a scheduled action based on a CRON expression.
EXAMPLES
EXAMPLE 1
New-CommanderSchedule -CronExpression "* * * * *" -Action {
Start-Process Notepad
}
Starts notepad every minute.
PARAMETERS
-Action
The action to execute on the schedule.
Type: System.Management.Automation.ScriptBlock
Parameter Sets: (All)
Aliases:
Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-CronExpression
The CRON expression that defines when to run the action.
Type: System.String
Parameter Sets: (All)
Aliases:
Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.