line rule > change status on webform

  • 16 January 2007
  • 3 replies
  • 1 view

Badge +5

Hello,
We are now busy on our third workflow in K2 trough an ASP.NET 2.0 webform.
One of the things that we keep encountering is the fact that when we open a worklistitem on a webform that we want to display a list to the user where he can choose an option to continue in the workflow.

We have to manually check what activity he activated, and display a radiobuttonlist with FlowStates that trigger the K2 Event line.

Is there programmaticaly a way display the Event Lines that are connected to an Activity ?


3 replies

Badge +13
We store available actions the user can pick in Activity Data field ACTIONLIST (e.g. Approve,Reject) and the front-end gets this data, parse it and display to the user.
Badge +9

The attached code sample you shows two methods to programatically retrieve line rules:


1.) via the K2 Studio API


2.) Process Definition XML. Both of these methods require the reading of physical files. In the case of the K2 Studio API, the actual K2 Studio files, Solution (.ksn), Project (.kpj), Process (.kpr) and Code Modules (.kcm), must be located in a location that the executing .NET application can reach (this is usually on the server, but does not necessarily have to be). The Process XML file must also be in a location that the executing .NET application can reach.


 

Badge +9
I forgot to mention, that in next version of K2 (codenamed "K2[blackpearl]") this type of functionality will be supported with a new concept of Actions and Outcomes.

Reply