Microsoft Remote Data ServiceMicrosoft Remote Data Service*
*Contents  *Index  *Topic Contents

SortColumn Property

Sets or returns which column to sort the records by.

Syntax

DataControl.SortColumn = String
PartDescription
DataControlAn object variable that represents an RDS.DataControl object.
StringA String value that represents the name or alias of the column to sort the records by.

Applies To

RDS.DataControl

Remarks

The SortColumn, SortDirection, FilterValue, FilterCriterion, and FilterColumn properties provide sorting and filtering functionality on the client-side cache. The sorting functionality orders records by values from one column. The filtering functionality displays a subset of records based on a find criteria, while the full recordset is maintained in the cache. The Reset method will execute the criteria and replace the current recordset with a read-only recordset.

To sort on a Recordset, you must first save any pending changes. If you are using the RDS.DataControl, you can use the SubmitChanges method. For example, if your RDS.DataControl is named ADC1, your code would be ADC1.SubmitChanges. If you are using an ADO Recordset, you can use its UpdateBatch method. Using UpdateBatch is the recommended method for Recordset objects created with the CreateRecordset method. For example, your code could be myRS.UpdateBatch or ADC1.Recordset.UpdateBatch.

Example

See Also

Sorting and Filtering


Up Top of Page
© 1997 Microsoft Corporation. All rights reserved. Terms of Use.