WebPageRequest, WebPageResponse, WebPageTransfer, WebPageRedirect activities
A set of custom activities for ASP.NET integration.
Similar to WebService Receive/Response, WebPage Receive/Response will integrate with Http Receive/Response and will help integrate Workflows in ASP server side logic. WebPage code behind class has to be derived from WorkflowWebPage. Workflow type to use is passed as parameter in webpage class constructor
Features:
- Ability to add web page parameters in designer, which will be populated out of Http context
- Ability to use acitivity bind to bind parameters and use HTML get/post parameter values in rules/condition expressions
- Ability to use in both Sequential and State Machine workflows
- Includes an ASP.NET web control sample as data bind sample
- Includes a Sequential driven and a State Machine driven website sample.
ASP.Net code behind class should derive from WorkflowPage class. WorkflowPage inherits from System.Web.UI.Page. This will populate RequestParameters collection for all WebPageRequest activities that point to this page. Page is identified by code behind class name. This property should be set on WebPageRequest activity. When http request arrives, an item will be enqueued into the queue with given page name. If this is a state machine workflow, correspondent state transition will fire up. In a sequential designer the request activity should be in execution state. In sequential designer, multiple activities can listen to different page requests by placing them in an EventHandlingScope activity.
Workflow author should manually define parameters on PageRequest activities depending on what HTML parameters he is expected in page request. A PageRequest parameter is defined using Parameters property. After adding an item to parameters property collection and save, a new dynamic property will appear in property browser. That property should be bound to a new member (field) in order to become available in Rules Editor. Dynamic properties can not be directly accessed.
A parameter collection is available on WebPageResponse activity. Every parameter added here can be bound to an issued field of request parameter or any other member. Response parameter values can be accessed from asp code using <%=...%> or using WorkflowParameter ASP.NET control.
Download:
http://wf.netfx3.com/files/folders/control_flow/entry4354.aspx