View Full Version : Query assigned to a button


Young20
11-03-2006, 07:18 AM
I have made a query for each column in my table in order to sort by ascending order. I want to assign this Query to a column heading button on my form. What is the code, or how do I go about assiging this query to this button so every time it is clicked the data is sorted according to what that query says?

KenHigg
11-03-2006, 07:24 AM
The short answer is to utilize the OrderBY attribute of the form. :)

Rickster57
11-03-2006, 07:32 AM
Check out this link.....
http://www.candace-tripp.com/pages/access_downloads.aspx

I posted this yesterday for someone that wanted to open a form and sort a listbox which contained several columns. This will allow you sort by any of the columns in your listbox.

Don't know if this is exactly what you are looking for but it is food for thought.