I've developed a process (workflow template) within Documentum Workflow Designer. This process includes three manual activities, and for each activity, the performers are configured with the "Previous Activity Performer to Choose at Runtime" option. I'm utilizing the following code to initiate the workflow and successfully complete a task.
//Initiate workflow
IDfWorkflowBuilder bldr = this.session.newWorkflowBuilder("process id");
IDfWorkflow workflow = bldr.getWorkflow();
bldr.initWorkflow();
//To complete workitem
IDfWorkitem wi = (IDfWorkitem) this.session.getObject(new DfId(workItemId));
if (wi.getRuntimeState() == 0) {
wi.acquire();
}
wi.complete();
How to pass the performer dynamically during the initiate a workflow and completing a task?