M
Microsoft Newsgroups
Access XP here, if it matters.
User opens a Select query in datasheet view and does a manual sort on a
field. Close, reopen, and Access remembers the sort order.
How can I reset that in code at runtime, so that my original sort
instructions from the QBE grid are restored?
To clear the query properties Order By property, I tried this:
Dim qdf as DAO.Recordset
Set qdf=CurrentDB.QueryDefs("MyQuery")
qdf.OrderBy=""
Access didn't like the last line, qdf.OrderBy = ""
Help appreciated.
Mark Hammer
Lake Oswego, Oregon, U.S.
User opens a Select query in datasheet view and does a manual sort on a
field. Close, reopen, and Access remembers the sort order.
How can I reset that in code at runtime, so that my original sort
instructions from the QBE grid are restored?
To clear the query properties Order By property, I tried this:
Dim qdf as DAO.Recordset
Set qdf=CurrentDB.QueryDefs("MyQuery")
qdf.OrderBy=""
Access didn't like the last line, qdf.OrderBy = ""
Help appreciated.
Mark Hammer
Lake Oswego, Oregon, U.S.