Workflow::activateFromWorkflowType Method [AX 2012]
Activates a workflow from a specified workflow template name.
Syntax
server public static WorkflowCorrelationId activateFromWorkflowType(
WorkflowTypeName _workflowTemplateName,
RecId _recId,
WorkflowComment _initialNote,
NoYes _activatingFromWeb,
[WorkflowUser _submittingUser])
Run On
Server
Parameters
- _workflowTemplateName
Type: WorkflowTypeName Extended Data Type
The workflow template name of the workflow configuration to enable.
- _recId
Type: RecId Extended Data Type
The record ID of the workflow enabled record.
- _initialNote
Type: WorkflowComment Extended Data Type
The comments that are associated with the enabled workflow.
- _activatingFromWeb
Type: NoYes Enumeration
A flag that represents the origin of the submission.
- _submittingUser
Type: WorkflowUser Extended Data Type
The user who submits the document to the workflow; optional.
Return Value
Type: WorkflowCorrelationId Extended Data Type
The ID of the workflow instance that will be used for correlation.
Remarks
Activation conditions are evaluated for every active workflow for the related workflow template. The first workflow that evaluates to true will be enabled. If no configuration is found after evaluating the activation conditions, the default workflow will be chosen.