Table "Scheduled Task"

ID 2000000175
Namespace: System.Environment

Manages scheduled task execution in Business Central, storing task metadata, execution context, and failure handling information.

Remarks

This table stores scheduled tasks that can be executed at specific times or intervals within Business Central. Each task includes execution context (user, company, language), timing constraints, and references to codeunits for both successful execution and failure handling. Supports timeout management, authentication delegation, and maintains execution state and error information. Used by the task scheduler framework to manage background task execution and provide reliable task processing capabilities.

Properties

Name Value
Caption Scheduled Task
DataPerCompany False
ReplicateData False
Scope Cloud

Fields

Name Type Description
ID Guid

Unique identifier for the scheduled task.

"User ID" Guid

Security ID of the user under whose context the task will execute.

"User Name" Text[50]

Name of the user under whose context the task will execute.

"User Language ID" Integer

Language ID for the user context in which the task will execute.

"User Format ID" Integer

Format ID for the user context in which the task will execute.

"User Time Zone" Text[32]

Time zone setting for the user context in which the task will execute.

"User App ID" Text[20]

Application ID associated with the user context for the task execution.

Company Text[30]

Company context in which the scheduled task will execute.

"Is Ready" Boolean

Indicates whether the task is ready for execution.

"Not Before" DateTime

Earliest date and time when the task should be executed.

"Run Codeunit" Integer

ID of the codeunit that will be executed when the task runs.

"Failure Codeunit" Integer

ID of the codeunit that will be executed if the task fails.

Record RecordId

Record reference that the task will operate on, if applicable.

Timeout Duration

Maximum duration allowed for task execution before timeout.

"Tenant ID" Text[128]

Identifier of the tenant where this task should execute.

"Last Error" Blob

Error information from the last failed execution attempt.

"Auth Delegation Related Record" RecordId

Record reference for authentication delegation, if used.

"Auth Delegation Type" Enum System.Environment."Scheduled Task Auth Delegation Type"

Type of authentication delegation to use for the task execution.

SystemId Guid
SystemCreatedAt DateTime
SystemCreatedBy Guid
SystemModifiedAt DateTime
SystemModifiedBy Guid
SystemRowVersion BigInteger

See also