Problem solve Get help with specific problems with your technologies, process and projects.

Is there some sort of code formatter that will let me format others' source code files to my own sta

I know you can use the command Ctrl+K,Ctrl+F to format selected code, but is there some tool or add-in that will allow me to fix other things other than tab indentions? Some kind of code formatter that will allow me to format other peoples source code files to my own standard settings? With the .NET CodeModel I figure someone has written one. In fact, I'm thinking about trying to write my own.
There are a few more settings than just tabs that you can change in the automatic and manual code formatting provided by VS.NET. Tools -> Options -> Text Editor -> C# -> Formatting shows the available C# formatting options (as you can see in TODO).

Figure 1: C# formatting options
Figure 1: C# formatting options

For prose, I prefer the settings as shown, because I like the opening brace on the same line as the construct. For example:

if( foo ) {

I find this style better suited to a small amount of space than the formatting settings as provided out of the box:

if( foo )

Of course, these aren't all possible settings, but I find them to be the kinds of things that I've wanted to change when formatting code.

Dig Deeper on Win Development Resources

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.