Sorting Of Data

nathangoldhill

Registered User.
Local time
Today, 00:30
Joined
Aug 6, 2001
Messages
12
My form seems ro be sorting my data and I dont want this to happen. I want the data to appear in record form as its typed in. so a new record appears as the last record. This is not happening at the moment any ideas?
 
You can set the OrderBy property in the form's properties. Access help has some examples.

This is taken directly from the help files:

The OrderBy property is a string expression that is the name of the field or fields on which you want to sort records. When you use more than one field name, separate the names with a comma (,).

When you set the OrderBy property by entering one or more field names, the records are sorted in ascending order. Similarly, Visual Basic sorts these fields in ascending order by default.

If you want to sort records in descending order, type DESC at the end of the string expression. For example, to sort customer records in descending order by contact name, set the OrderBy property to "ContactName DESC".

HTH
 
The ONLY way to maintain a data entry sequence is to sort on a unique identifier that is assigned when the row is added to the table. Your choices are a sequential autonumber or a date/time field with a default of Now(). The former is preferable since it is not manually changeable.

If you have one of these two field types in your table, you can base the form on a query with an order by clause.
 

Users who are viewing this thread

Back
Top Bottom