How do I create the facility for users to define their own sort o.

G

Guest

I have set up search form (using VBA) and want to add a facility for users to
define the order in which results are displayed. I am using Access 2000.
 
S

Scott McDaniel

Well, we don't know how you're performing your searches, but if you're
building SQL strings for searching, you can simply add an ORDER BY clause to
the SQL string. For example:

SELECT * FROM SomeTable WHERE Field1='Bob' ORDER BY SomeField

You'd present your users with a list of the fields they could choose for
sorting and build your string from there ...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top