views:

242

answers:

2

I have a SharePoint (WSS 3.0, VS 2005) workflow that has a workflow modification form attached to it, which I would like to disable after a certain time and continue with the parameters from the association form.

What's the best way to move past the 'onWorkflowModified' activity if the timer is up? It seems that the only way to listen for modification data results in the workflow waiting indefinitely at the activity.

Thanks!

EDIT: The 'onWorkflowModified' activity in one branch of a parallel activity stops anything from happening until it is dealt with - this is what I'm trying to avoid.

A: 

You could probably run parallel activities. one that listens and another that waits for an event. If either are stepped through you could cancel the other. You don't need to do anything specifically in the onWorkflowActivated step. It is only required by SharePoint to start a workflow and provide your initial data.

webwires
A: 

It turns out that, as suspected, 'onWorkflowModified' inherits from 'HandleExternalEventActivity', which is a blocking activity. As a result, having it as a branch in a parallel activity causes the workflow to stop until it is dealt with. The easiest way to get around it is to fire the event it's waiting for when the timer is up, and differentiate between receiving the event from the timer, and the user.

Hopefully this can help someone else!

Andy Mikula