2

Related to my other question: What's the best way to layout a C# class?

Is there a way in ReSharper to define the order you want your members to be in, so that ReSharper will maintain it?

Community
  • 1
  • 1
Ray
  • 45,695
  • 27
  • 126
  • 169

2 Answers2

5

From this answer:

Check under Type Members Layout in Options (under the C# node). It's not simple, but it is possible to change the layout order.

Community
  • 1
  • 1
Michael Meadows
  • 27,796
  • 4
  • 47
  • 63
0

Check File and Type Layout in Resharper's help documentation -

ReSharper can reorder types and type members in C# files according to different patterns. Patterns can describe a lot of conditions and constraints that are evaluated when reordering items in a file and/or wrapping them with specified regions.

The page describes how those patterns work, how to configure them (two options here - use a visual editor or edit the XAML source) and finally, how to apply your settings.

pius
  • 119
  • 2
  • 2
  • 13