Create a simple Workflow console application using Xaml Workflow
Go to new project in Visual Studio 2013 and select Installed>Templates>Visual C#>Workflow>Workflow Console Application
Give it a name “WindowsWorkflow.ConsoleApp”
![](https://365rack.com/wp-content/uploads/2020/06/WWF1-300x128-1.png)
Delete Workflow1.xaml file as we will be adding a new file
![](https://365rack.com/wp-content/uploads/2020/06/WWF2-300x182-1.png)
Right click on project and add a new file of Workflow and give it a name “MyAddress.xaml”
![](https://365rack.com/wp-content/uploads/2020/06/WWF3-300x182-1.png)
Now from the toolbar drag and drop Sequence (Under Controlflow listed)
![](https://365rack.com/wp-content/uploads/2020/06/WWF4-300x161-1.png)
Now from toolbar drag and drop WriteLine (under Primitives)
![](https://365rack.com/wp-content/uploads/2020/06/WWF5-300x161-1.png)
Now right click on WriteLine and go to properties
Change the DisplayName to Addres and text to “What is your address?”
then save the changes
![](https://365rack.com/wp-content/uploads/2020/06/WWF6-300x161-1.png)
Now drag and drop Assign under Address.
![](https://365rack.com/wp-content/uploads/2020/06/WWF7-300x161-1.png)
Select sequence and then go to variables and add a new variable and give it a name – leave rest like it is
![](https://365rack.com/wp-content/uploads/2020/06/WWF8-300x161-1.png)
Right click on Assign, go to properties and change the values to
> To = Address
>C# expression = Console.ReadLine()
Address is our variable we have declared previously and Console.ReadLine() will take input from user
![](https://365rack.com/wp-content/uploads/2020/06/WWF9-300x161-1.png)
Now drop an other WriteLine at the end and change the values as below
![](https://365rack.com/wp-content/uploads/2020/06/WWF10-300x161-1.png)
Now go to Program.cs and change the values as below
static void Main(string[] args)
{
Activity workflow1 = new MyAddress();
WorkflowInvoker.Invoke(workflow1);
}
Once done, build your project
then ctr + F5 to get the results
![](https://365rack.com/wp-content/uploads/2020/06/Windows-Workflow-Final-Step-300x151-1.png)
This will ask you to enter your address and then display results.
This was a very basic program on Windows Workflow which can be extended to use more activities inside of it.
Complete source code below