Is there an Enum natively in .NET for asceding or Desceding ordering?
I need to use the ordering concept in different libraries, and I want loose coupling as possible.>
Interesting point relating to Windows.Forms.SortOrder and Data.SqlClient.SortOrder
Upon inspection the first has values:
public enum SortOrder
{
None = 0,
Ascending = 1,
Descending = 2,
}
while the second has values:
public enum SortOrder
{
Unspecified = -1,
Ascending = 0,
Descending = 1,
}
Probably a good idea to be consistent, especially if serialising.