So I have a query where I can grab the data using Dlookup() but it only returns first record. Sometimes I have more than one record. I'd like to add a NEXT button to display the next record when clicked if it exists. Any help would be appreciated.
So I have a query where I can grab the data using Dlookup() but it only returns first record. Sometimes I have more than one record. I'd like to add a NEXT button to display the next record when clicked if it exists. Any help would be appreciated.
Why does query result in only one record?
Is the query used as RecordSource for a form?
Could use intrinsic record navigation bar. If you want custom buttons for 'previous' and 'next', try the design wizard for creating buttons.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
Well I have a seach portion to form. Users enter in last name and birthdate and when the text boxes match the query I've set up, I grab the customer ID, set the current record with the after update. Currently I added a button to display all matches from query in query mode. But would prefer a way which I can: count number of results in query (dcount), grab data from second row (if there is say two matches)
Why the second (or last) row?
Maybe just set the sort order to Descending?
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.