Code Sorting Tool for .NET
Are there any tools for sorting and organizing tools for C#/VB. Specifically one that does stuff like moving all the fields to the top of the file开发者_StackOverflow社区, alphabetizing the methods, etc.
ReSharper has the ability to do this. If you go to ReSharper -> Options -> Code Cleanup
you can enable the Reorder type members
option. This enabled the code reordering when you do a code cleanup (ReSharper -> Tools -> Cleanup Code...
).
There is also an option to set a custom template to specify how to rearrange the code. This can be set in ReSharper -> Options -> C# -> Type Members Layout
.
精彩评论