Show / Hide Table of Contents

    IDwTable.Sort Property

    .NET Standard 2.x

    Gets or sets the sort criteria for the DataWindow.

    Namespace: DWNet.Data

    Assembly: DWNet.Data.dll

    Syntax

       IExpressionable<string> Sort { get; set; }
    

    Property Value

    DWNet.Data.IExpressionable<System.String>

    An IExpressionable<string> object which represents the sort criteria for the DataWindow.

    Remarks

    The Sort property sorts the data before it is retrieved. To sort data in the DataWindow buffer, use the IDataStore.SetSort and IDataStore.Sort methods.

    Examples

    The following code example demonstrates how to get the DataWindow.Table.Sort property.

    using DWNet.Data;
    using System;
    
    namespace Appeon.ApiDoc.IDwTableExamples
    {
        public class SortExample
        {
            private readonly SchoolContext _context;
    
            public SortExample(SchoolContext context)
            {
                _context = context;
            }
    
            public void Example()
            {
                // Creates a new DataStore object.
                var course = new DataStore("d_course", _context);
    
                // Gets the DataWindow.Table.Sort
                var sort = course.DwMeta.DataWindow.Table.Sort;
    
                // A string containing the sort defined in the DataWindow. 
                string expression = sort.Expression;
            }
        }
    }
    

    Applies to

    .NET Standard

    2.x

    Back to top Generated by Appeon