Click here to Skip to main content
15,942,094 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I am using Microsoft Visual Studio 2010.I have created workflowdesigner in VS 2010.Recently it it migrated to VS 2012.

My problem is I am not able to display or add an end step/activity to the flowchart.
By default start node is getting visible and I can add steps to the start node etc is possible.

I have tried with the below code.But failed.
private void AddDesigner()
{
//Create an instance of WorkflowDesigner class.
this.wd = new WorkflowDesigner();

//Place the designer canvas in the middle column of the grid.
Grid.SetColumn(this.wd.View, 1);

Flowchart flow = new Flowchart();
flow.DisplayName = "Designable Flowchart";

//add the end step to the flow chart by default
FlowStep endStep = new FlowStep();
endStep.Action = new End(); // <---- this is the custom activity (End())
flow.Nodes.Add(endStep);

ActivityBuilder mRootActivityBuilder = new ActivityBuilder();
mRootActivityBuilder.Implementation = flow;

wd.Load(mRootActivityBuilder);

//Add the designer canvas to the grid.
grid1.Children.Add(this.wd.View);
}


But can any one please help me to add/create end step also.

Thanks in advance.
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900