Blog
Blog posts on .NET, Azure, and more.
"Remove and Sort" namespaces using shortcut in Visual Studio
August 06, 2014 by Anuraj
.Net Visual Studio
If you are using StyleCop for maintaining C# coding standards and conventions, we used to do Remove and Sort namespaces feature from Visual Studio. The Organize Usings options in the Visual Studio integrated development environment (IDE) provide an easy way to sort and remove using and extern declarations without changing the behavior of the source code. Over time, source files may become bloated and difficult to read because of unnecessary and unorganized using directives. The Organize Usings options compact source code by removing unused using directives and improves readability by sorting them. I am huge fan of keyboard shortcuts, but by default VS did come with a keyboard shortcut for this feature. This post is about adding a keyboard shortcut to Remove and Sort.
Create Custom Configuration Sections in .Net
July 15, 2014 by Anuraj
.Net .Net 3.0 / 3.5 .Net 4.0 ASP.Net ASP.Net MVC Visual Studio
This post is about creating custom configuration sections in .Net. If you search for this topic in internet, you will find lot of code snippets and blog posts(Here is the MSDN link). Unlike that, this post is about a nice tool, .NET Configuration Code Generator which will help you to generate code for you to create custom configuration section. It is a free, open source tool licensed under Apache License 2.0 (Apache).
Read Excel as DataTable using OpenXML and C#
July 11, 2014 by Anuraj
.Net .Net 3.0 / 3.5 .Net 4.0 ASP.Net ASP.Net MVC
In the current project we were using OpenXML extensively for reading Excel files. Here is the code snippet, which will help you to read / convert Excel files to DataTable.
How to pass parameters to Work Flow
July 02, 2014 by Anuraj
.Net ASP.Net WF Windows Forms
You can create arguments to workflow and can pass the values from outside. For creating arguments, you can use the Arguments Tab in the WorkFlow designer.
How to load WF workflows dynamically
July 01, 2014 by Anuraj
.Net .Net 4.0 ASP.Net MVC WF Windows Forms WPF
This is post is about loading and running Workflow foundation (WF) XAML files. It is a powerful technique which can be used to change Workflows on the fly, without re-compiling the application. All this functionalities can be achieved via single line of code.
Copyright © 2024 Anuraj. Blog content licensed under the Creative Commons CC BY 2.5 | Unless otherwise stated or granted, code samples licensed under the MIT license. This is a personal blog. The opinions expressed here represent my own and not those of my employer. Powered by Jekyll. Hosted with ❤ by GitHub