Visual Studio Tips and Tricks - II
There are at times when you would like to format your code properly, especially with xml stuffs including html tags. Indention provides you with much clarity in your code. Just looking at it you can understand much of it. Even makes your debugging easier. Its really an important part of code organization.
So how would you do it in a traditional way.
Tab.. oh i’m wrong
shift + tab. Well, those are gone with the old ages. Now its even better than before.
Ctrl + k, Ctrl + d. What you do is Press
Ctrl + K and then after some time press
D while holding
Ctrl. Don’t wait too long. You’ll get used to it. Its just a matter of practice. After all practice makes a man perfect.
It works with almost any languages, whether it is xml files, html, C# or .aspx files.
In short I like to call this
Ctrl + kd. After finding this magical sequence of keys, it has really help me speed up my coding time.
Ctrl + KD
Ctrl + KD
As you can see, it even automatically moves excess text to you next line so that it can be fit on you screen easily.
For more articles on tips and tricks refer here. Or you can also access the page from the right menu under Page List heading