I open a dialog initiation window of my sequential workflow from ECB menu. There is a start button on it. When this button is clicked the workflow starts working and the dialog window stays open. How can I start the workflow and then close the window immediately? For example, start workflow asynchronously.
I have found the answer. I use
Web.Site.WorkflowManager.StartWorkflow(workflowListItem, association, GetInitiationData(),SPWorkflowRunOptions.Asynchronous).
But there is other issue: workflow starts working after 3-5 minutes.