Vertical Column Indicator for Visual Studio
The coding guidelines at my job have a rather interesting requirement: code must be wrapped at 100 characters. If you fail to meet this on any line of code, you fail the code review. In the year I’ve worked at this company I’ve learned to guess how long a line is quite well. As of today, no more guessing.
Here’s a quick registry hack to add a vertical line in the editor at any column you wish, just double click the REG file and you’re set. The contents of the file look something like this:
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\
VisualStudio\8.0\Text Editor]
"Guides"="RGB(128, 128, 128) 100"
[HKEY_CURRENT_USER\Software\Microsoft\
VisualStudio\7.1\Text Editor]
"Guides"="RGB(128, 128, 128) 100"
The setting works something like this: The RGB() part defines the color of the line, the number at the end defines the column the line is displayed at. If your style defines a limit on the length of a line, this is a great way to see at a glance if you’re going too long.
Note: This adds the key for both Visual Studio 2003 and Visual Studio 2005.
Update: The original REG file I linked to had a formatting error that caused the data to import improperly. I’ve replaced the file with a working copy.
Welcome!
I am a software developer, currently located in Virginia. While my primary focus is creating software on Microsoft's .NET stack, I also write about other topics and technologies I find interesting - Ruby on Rails, Security, and even a little about photography.Search
Articles
- January 2012
- October 2011
- July 2011
- June 2011
- May 2011
- April 2011
- March 2011
- February 2011
- January 2011
- December 2010
- August 2010
- July 2010
- June 2010
- April 2010
- February 2010
- December 2009
- October 2009
- July 2009
- June 2009
- December 2008
- November 2008
- October 2007
- August 2007
- May 2007
- April 2007
- March 2007
- February 2007
- January 2007
- December 2006
- November 2006
- October 2006
- September 2006
- August 2006
- July 2006
- June 2006
- May 2006
- April 2006
- March 2006
- February 2006









