Wednesday 4 April 2007

Xml attribute formatting

If you spend a lot of time formatting your xml documents with each attribute lined up on a seperate line, you will be pleased to know that there is an option in VS 2005 which allows you to do this automagically.

Tools-->Options-->Text Editor-->Xml-->Formatting

switch the radio button to "Align attributes each on a seperate line".

then ctrl-k, ctrl-d your way to easy to read xml files.

Most useful when something updates your xml for you, like updating a WCF service reference.

No comments: