By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,968 Members | 1,589 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,968 IT Pros & Developers. It's quick & easy.

Ordering a form based on a table?

P: n/a
Simple question (I think)...

I have a form based on a table and I want it to open with it sorted on
Last Name ascending.

I set the order by property for the form to: tblPersonnel.[Last Name]
ASC
but it opens ordered on the PID, which is an autonumber.

Why does it ignore my order by selection?
Thanks,
Blake

Aug 10 '06 #1
Share this Question
Share on Google+
1 Reply


P: n/a

gb********@gmail.com wrote:
Simple question (I think)...

I have a form based on a table and I want it to open with it sorted on
Last Name ascending.

I set the order by property for the form to: tblPersonnel.[Last Name]
ASC
but it opens ordered on the PID, which is an autonumber.

Why does it ignore my order by selection?
Thanks,
Blake
Make sure you set the .OrderByOn property as well

Me.OrderBy = MyColumnName
Me.OrderByOn = True

KingOfChi

Aug 10 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.