Finish an Activity, get URL of next client event

  • 4 August 2006
  • 0 replies
  • 0 views

Badge +2
Hi,

I have a requirement where, under certain circumstances, a user should be able to finish an activity and then get the next workflow item immediately, so that the Data property and therefore the url of the next activity's client event can be obtained.

The sequence I envisage is:

get the folio for the process instance
call Finish() on the activity (synchronously)
get the user's worklist, filtered by folio = this folio and
activity name = required activity name for uniqueness.
open the single item returned
get the Data property
do a Response.Redirect using the Data as the argument.

This seems a bit messy to me, and I feel sure that, although the first activity is guaranteed to finish, there is no guarantee that the next activity will have started by the time I request the worklist, so there is every chance that the worklist will be empty.

Has anyone else hit this requirement and come up with a clean solution? The idea is to do everyting in the context of one round trip to the server so that the pages are served up in sequence with no intermediate trips to a worklist page.

Thanks

0 replies

Be the first to reply!

Reply