Skip to main content
Hi, could someone please help me on this one I've tried troubleshooting for some time but I've found no solution.

When I use the following code to create a process instance in the code behind of a webform, the worklist item's link in my workspace shows up as http://K2Employee/HR2.aspx?sn=PIERRE,42,25, instead of
http://localhost/K2Employee/HR2.aspx?sn=PIERRE,42,25.

Basically it is missing the localhost part so when I click on the worklist item to view its details, an "action cancelled" error appears in the right pane because the url is wrong.

Here is the code in question I use to start the process:

SourceCode.K2ROM.Connection oK2Connection = new SourceCode.K2ROM.Connection();

SourceCode.K2ROM.ProcessInstance oNewProcessInstance;
oK2Connection.Open("localhost");
oNewProcessInstance = oK2Connection.CreateProcessInstance("HRNewEmployee");
oK2Connection.StartProcessInstance(oNewProcessInstance, true);
oNewProcessInstance.Update();

Iv'e added an image of the worklist item screen to help in understanding the problem.

Any ideas are greatly appreciated,

Thanks!
I don't think the problem is on your web page. I think the problem lies within your process definition i.e. K2.net Studio design.

What does your 'Client Event' URL or code behind the client event look like?

Regards,
Ockert
You are right!
Thank you so much you saved me a lot of time I never thought of double checking the client event url !

Regards,

Pierre

Reply