I’m a huge fan of Visual Studio extensions – both consuming and creating them. Whenever I come across a missing feature in Visual Studio, my first instinct is to search for an extension that provides it. If it doesn’t exist, I create it.

In the past couple of months, I’ve created 3 tiny extensions that each adds features I’ve been missing. Each of these are highly specialized and solves a single problem each.

Trailing Whitespace Visualizer

I like my code files clean and without unneeded trailing whitespace. Format Document (ctrl+k, ctrl+d) takes care of removing the trailing whitespace, but I’d like to see it clearly in the editor while coding. Here’s what it  looks like:


The color can be customized in case you don’t like red.


Download Trailing Whitespace Visualizer on the VS Gallery

Error Watcher

I don’t normally have the Error List visible in Visual Studio, so I often save files containing errors, just to find out that my project won’t build or work at runtime. That’s annoying. I wanted a more visual way to be informed about errors without looking at the details in the Error List. My solution was to show the number of errors on the file containing them at the top of the editor window.


When no errors exist in the file, nothing will be shown in the editor. If you save the document with errors, a small red line will flash briefly to make you aware of it.

Download Error Watcher on the VS Gallery

Add empty file

Often times I just want to add an empty file to my project. It could be a .json or .js file for instance. In cases like that, I find that going into the Add New Item dialog takes to long and I sometimes have to search for the file type I want. It would be easier if I could just enter the file name with the extension I want and have it created for me. Also, the Add New Item dialog doesn’t allow me to create file names starting with a dot like in .gitignore.

I added a button to the Add flyout context menu:


This will prompt me for a file name:


Here I can type whatever file name I want and it will be created, added to my project and opened in the editor.

Download Add Empty File on the VS Gallery

Remember, unlike some browsers, Visual Studio doesn’t slow down when using multiple extensions. Most of them only load in specific circumstances and doesn’t do anything when not used. That’s true for these three extensions too.

All three extensions are of course open source on GitHub.


Comment by Kerry Jenkins

Thanks Mads for all of your work and making it available on GitHub for all to learn from. You work is appreciated!

Kerry Jenkins

Comment by Rob Karatzas

Off topic question: Anyway we can get an extension which will let us use a different search provider in VS?

Really sorry, but Search in VS totally blows chunks...

I'm use to using Actual Search and Replace: http://www.divlocsoft.com/

and no, I don't work for them nor do I have a financial interest in this company.

never liked 99% of MS search products and told Guthrie in 2001 that Site Server Search blows chunks, and that you had better watch out because somebody is going to take over that space (-> Google)


Comment by Rob Karatzas

Another one (while working with Visual Studio 2013 Ult.) today. Is there anyway to elevate privileges in VS after the fact? VS tells me .config is "mucked up", double-click on the .config, make changes (my bad), and try to save you get (idiotic messages like):

Access Denied (WTF, I've already looked at and edited the file)

At least try to do something sensible (versus absolute babble).


Comment by Eduardo

Can I suggest a new extension that could be very useful? Duplicate file (or item) -> Creates a new file with the same content and prompt to edit the file name.

I always start a new file using one that's pretty similar and then replace and made changes to it.

Comment by Rob Karatzas

@Tony don't get me wrong, I do love this product. I was an ASP Ace before there was C# (think it was called "cool") and there was an ASP.NET. Was using it before it was ever released :)
(Gave a lot of feedback to the ASP.NET team over 2 years 2000-2001 :)

Comment by Rob Karatzas

I beg of you Mads, if you have any influence with VS, can we get a permanent setting on this:
"You have mixed tabs and spaces. Fix this?"

I'd just like to set it as a standard for my developer group.

I appreciate it that it tells me this, but not 200 times a day.

(So set it ONCE in options, by language, if it see's a default white space setting, don't keep popping up, just do what I'm telling you in settings. :)


Comment by Anders Eriksson

One thing that would make Add empty file perfect, would be if there was a checkbox for not adding the file to the project.
I like Visual Studio editor but now I "need" to use a separate editor for temp files. So please add a way of creating an empty file that's not added to the project!


Anders Eriksson

Comment by Rob Karatzas

@Mads will take a look at this over the weekend (and will see how this can be applied to various C# applications we develop in VS). Haven't looked at Visual Studio Online, but will need to check this out as well.