![]() |
|
|
#1
|
|||
|
|||
|
I am trying to set up a FIND function on a screen. I do not want to use the FIND from the menu. The user wants to be able to enter a number in a field, and have the screen go to the correct record. Then I want to set the focus back in this field so I can do another find. The idea being minimal data entry.
I am looking for suggestions for how to do this. Thank you in advance. Laurie |
|
#2
|
|||
|
|||
|
you can do it through a filter.....
create a textbox and a button and add the following code to the click event or use the change event to have the form filter as he user types... This is an example from a project i worked on : Code:
Private Sub txtCustomID_Change()
txtCustomID.SetFocus
Me.Filter = "CustomID LIKE '" & txtCustomID.Text & "*'"
Me.FilterOn = True
txtCustomID.SetFocus
txtCustomID.SelStart = Len(txtCustomID.Text)
End Sub
|
|
#3
|
|||
|
|||
|
Hmm...interesting. I am currently working on a project that requires the same.
I have been using "FindRecord" action in a macro, but it has not been the best option. One problem is that it has to start over from the first record after each search. It also seems to "go bad" easily where the database has to be restarted. (Though I could be using it incorrectly) I may try this code as well. PK |
|
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Find data, load data, and save as a new record | hawzmolly | Access | 0 | 10-05-2008 01:18 PM |
| query to find the highest value in a field | jhjarvie | Queries | 0 | 09-02-2008 12:27 PM |
| Deleting Record Contents, not complete record... | Charles Waters | Access | 2 | 06-24-2008 10:00 AM |
| can't find language DLL | tequila | Access | 0 | 05-01-2008 07:31 PM |
| How do I find the serial value of Now()? | JoeG | Queries | 0 | 03-13-2007 06:16 AM |