JobStep.OnSuccessAction JobStep.OnSuccessAction JobStep.OnSuccessAction Property


Gets or sets the action to take when the job step finishes execution with success.

 property Microsoft::SqlServer::Management::Smo::Agent::StepCompletionAction OnSuccessAction { Microsoft::SqlServer::Management::Smo::Agent::StepCompletionAction get(); void set(Microsoft::SqlServer::Management::Smo::Agent::StepCompletionAction value); };
public Microsoft.SqlServer.Management.Smo.Agent.StepCompletionAction OnSuccessAction { get; set; }
Public Property OnSuccessAction As StepCompletionAction
Property Value

A StepCompletionAction object value that specifies the action to take when the referenced job step finishes execution with a completion status of success.


Scheduling Automatic Administrative Tasks in SQL Server Agent


When a job step finishes execution it has status specified by the CompletionResult object value. This is recorded in the LastRunOutcome property for the job step when it was last executed. If the job step completed with success, the next steps are determined by the OnSuccessAction property.

Applies to