workflow-activity

Expose NativeActivity Variables to Workflow Designer

I've got a NativeActivity which contains an Activity body. The purpose of this activity is to expose a resource for the duration of the child activity as a Variable. The problem I've encountered is it appears the Variable cannot be used outside the activity. I'll use StreamReader as an example resource. ResourceActivity.cs: [Designer(t...

How can I write a custom WorkFlow 4 Code Activity that includes a "Body Block"?

Is this possible? I know it is for MS since they have WF activity packs but I'm not sure how it's done. It would be nice to be able to have Activities with Body blocks to insert other activities, buttons, etc. If not too much trouble and/or time consuming that is. ...

What am I doing wrong with my Workflow bookmark pick trigger?

I have a NativeActivity derived activity that I wrote that is to use bookmarks as a trigger for a pick branch. Using something I found on MSDN I tried writing this to trigger the branch. The branch contains activities that fire service callbacks to remote clients via send activities. If I set a delay for the trigger, callbacks fire to th...

How to assign an argument to the variable in Workflow Foundation 4.0?

Hi Guys, This simple code fails with the following error: The following errors were encountered while processing the workflow tree: 'ArgumentValue': The argument named 'Parameter' could not be found on the activity owning these private children. ArgumentReference and ArgumentValue should only be used in the body of an Activity defini...

custom activity, set property default value

Hello I implement a custom activity in WWF. I have a property that must set to one of the existing states on host workflow. How can I set default value for this property that have to display all available states on workflow ( such as Target State in SetState Activity)? ...

How to get workflow instance in an activity?

I was not able get the workflow instance in code activity of my workflow.how do I get it? I did check WorkflowEventArgs.WorkflowInstance Property but in my code activity i do not have WorkflowEventArgs. instead i have EventArgs. What I am trying to do: basically, i need to access the Workflow queue data to get the values in queue. in ...

Workflow 3.5 Activity property is null in condition and nowhere else

I have an activity that has properties that look something like this (they're set up as proper dependency properties, I just kept it simple here): public List<MyType> TypeList { get; set; } public Int32 Index { get; set; } public MyType SelectedType { get; set; } and an execution that just does this: SelectedType = TypeList[Index]; ...

WF4: Many dynamic assemblies in current app domain ?

Full code: using System; using System.Linq; using System.Activities; using System.Activities.Statements; namespace ManyAssemblies { class Program { public sealed class SayHelloActivity : Activity { readonly WriteLine writeLine = new WriteLine() { Text = "Hello Workflow 4" }; public SayHelloActivity() { Imple...

scroll start point of a HorizontalScrollView

In the method onCreate, I tried to put a series of TextView in HorizontalScrollView and then I tried to set the value of the scroll to a TextView. Not working. When I find the TextView I need, i put it in a class field and when the cycle that inflates the TextViex is over, i ask to my good one TextViev its getLeft(), and it return me alw...

How can I add tooltips to activities in Rehosted Workflow Designer?

I have a Rehosted Workflow 4.0 Designer that includes both stock and custom activities. I can see icons through AttributeTableBuilder.AddCustomAttributes if I set ToolBoxBitmap attribute. However I am unable to see the tooltips on activities even if I set DescriptionAtribute. This is something I can see in case of VS designer. ...

Passing data back to workflow from various tasks created by the workflow.

Hi I have a workflow that generates multiple tasks based on some selections in the workflow. I am using a replicator activity to generate these tasks in parallel. These tasks are approval tasks and I need to save Approved Status (Aproved or Rejected) and a comment from the approver back into the list item which initiated the workflow. T...

Firing only the first of multiple HandleExternalEvent in ParallelActivity

I have a workflow that at some point contains a parallel activity with two external event handler activities in each parallel branch. Both HandleExternalEvent activities wait for the same event on the local service. I would like to execute only one of them based on parameter that comes from the local service. So far only the first branch...

How to customize activity in re-hosted Workflow 4 Designer?

This article shows how to create a custom activity in a rehosted Workflow designer (with Workflow Foundation 4). In that example, a MyDelayActivity is created by implementing the IActivityTemplateFactory interface, and specifying the default value to the Delay inputs. However, is it possible to modify the inputs of the activity as well...

Window WF activity designer to toolbox

I am trying to make an empty custom activity so that I can have comments in the workflow designer. I have an activity designer that does not do anything but has a text block so the comments can be added. What is the easiest way to get this into my workflow toolbox? I have an empty activity that is currently in the workflow toolbox, but I...