Opening the Most recent record

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have created a number of records and I what I would like to happen is when
I open the form I would like the most recent record (according to date) to
open. It appears that the first record entered opens first and the last
record entered opens last. I would like the reverse this. Any suggestons.
Frank
 
Realistically, data in tables has no guaranteed order: think of tables as
"sacks of data", where the data is shoved in wherever it fits.

The only way to ensure any specific order is to use a query with an
appropriate ORDER BY clause. Create a query that sorts the records by Date
and use that query as the RecordSource for your form, rather than the table.
 
You might try setting the sort value (OrderBy) in the form load event:

Me.OrderBy = "Field Name"
Me.OrderByOn = True

This would make the first record the most current.
 
Create a query based on your table. Sort the date field descending. Set the
recordsource of your form to this query. Your form will open with the record
with the most current date.

PC Datasheet
Providing Customers A Resource For Help With Access, Excel And Word
Applications
(e-mail address removed)
 
Back
Top