I have encountered a lot of bad HTML formating in my days, and one quick way to organize the HTML files via Visual Studio 2005 is to use the
Format Document option from the Edit menu.
One thing about the default settings for Format Document (or Selection), is that it will wrap lines by default, which to me, can be undesirable. To change this setting, go the
Tools ->
Options and then navigate the tree to
Text Editor ->
HTML ->
Format, and uncheck the Tag Wrapping check box towards the bottom of the page.
Here too you can set any specific HTML tag format options you would like to use. To do so, click the
Tag Specific Options button in the same group box.