--- myst: substitutions: method: |- ```{image} /img/code_reference/net_library/method.ico ``` prop: |- ```{image} /img/code_reference/net_library/prop.ico ``` --- # OrderBy Class Specifies options to use for ordering ERP entities. **Namespace:** powerGate.Erp.Client\ **Assembly:** powerGate.Erp.Client.dll ## Inheritance Hierarchy [System.Object]()\  **powerGate.Erp.Client.OrderBy** ## Syntax ```{code-block} CSharp :linenos: public class OrderBy ``` The OrderBy type exposes the following members. ## Constructors | Name | Description | |---------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------| | {{method}} OrderBy(string propertyName, OrderDirection? direction = null) | Initializes a new instance of the OrderBy class by passing the property name that should be ordered. | ## Properties | Types | Name | Description | |----------------------------------------------|--------------|--------------------------------------------------------------| | {{prop}} string | PropertyName | The property used to order a collection of entities. | | {{prop}} [OrderDirection?]() | Direction | Nullable. The order of a sequence (ascending or descending). | ## Remarks When the **OrderDirection** property is not set, the entities are ordered in the direction defined on the Erp-side (this should be ascending order by default). ## See also **Reference** - [powerGate.Erp.Client namespace]()