Tip/Trick: Increase your VS screen real estate by disabling HTML Navigation Bar

Below is a tip/trick I twittered via my Twitter account earlier today.  A number of people seemed interested in – so I thought i'd blog it here too.

HTML Navigation Bar in VS 2008

By default, when you are in HTML source-editing mode with VS 2008 and Visual Web Developer 2008 Express edition there is a set of drop-downs that are rendered immediately above the HTML text editor view:


This set of drop-downs is called the "Navigation Bar", and in the VS 2008 HTML editor they allow you to navigate between functions and methods defined within the HTML.  These include both JavaScript client-side functions defined inline within the .aspx/.html file, and server-side methods defined in-line within the .aspx file when in single-file mode (meaning no code-behind file).

Disabling the HTML Navigation Bar and Getting back some pixels

Personally I don't find the HTML navigation bar super useful – since I tend not to define JavaScript functions inline within the HTML (instead I use more unobtrusive JavaScript techniques and put my JavaScript code in separate files), and I usually use code-behind instead of single-file event handlers for server-side code.

If you are like me and also don't find yourself using that particular navigation toolbar much, you'll be happy to know that you can turn it off in VS 2008 and get back about 40-50 pixels that can instead be applied toward your HTML source code view.  To-do this, just select the Tools->Options menu item within VS, navigate to the "Text Editor->HTML" node and uncheck the "Navigation Bar" checkbox option:


Once you do this and press the "ok" button, you'll find that the drop-downs are gone and you have more screen real estate:


(Note: if there is no immediate change after you hit ok, try closing and then re-opening the HTML/ASP.NET file)

Hope this helps,


P.S. By default with VS 2010 (starting with Beta2) we are hiding the navigation bar when in HTML mode with the standard web profile – you can then turn it back on via Tools->Options if you find it useful.  VS 2010 also has a new optional "code optimized" web profile as well that turns off all toolbars, dropdown and HTML designers.


Comments have been disabled for this content.