~~NOTRANS~~
~~Title: Start Workflow on Server Side~~
If you want to start a specific workflow on server side in an [[jvx:server:lco:actions_in_objects|action]] of your [[jvx:server:lco:lifecycle|life-cycle object]], it's straight forward. Simply use the workflow access object and call one method:
WorkflowAccess wfa = WorkflowAccess.getCurrentInstance();
Obejct id = wfa.startWorkflow(worfklowNameOrId);
Be careful if you run above code outside the life cycle scope because
WorkflowAccess.getCurrentInstance();
tries to get the workflow access object via [[jvx:server:lco:sessioncontext|SessionContext]].
If you don't run inside the life cycle scope, use
WorkflowAccess wfa = new WorkflowAccess();
wfa.setDBAccess(dbAccess);
instead.