Search as you type (1 Viewer)

Kuleesha

Member
Local time
Today, 08:04
Joined
Jul 18, 2021
Messages
50
Hi,
I have 2 textboxes on my form (Namefilter and BirthYear filter) and have set them up to filter the data entered in my tables as i type (real time search as I type).
I need the 2nd filter (birthyear) to filter the results obtained by the first filter, but at the moment when I type in the BirthYear filter textbox it does the search from the original data and not the already filtered data.
How can I achieve my objective?
Ive attached my database below with some mock data.
 

Attachments

  • PatientsNew6.zip
    839.5 KB · Views: 245

Gasman

Enthusiastic Amateur
Local time
Today, 03:34
Joined
Sep 21, 2011
Messages
14,260
You need to combine both.
With your setup, might be better to enter birthyear first?
 

moke123

AWF VIP
Local time
Yesterday, 22:34
Joined
Jan 11, 2013
Messages
3,913
As Gasman points out you need to combine the 2 filters but I think there is a major twist.

I think you will need seperate procedures in the onchange events of each textbox.
If you are in the name textbox you will not be able to use the .text property on the year textbox , and vice versa. In order to use the .text property, the control needs the focus.
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 10:34
Joined
May 7, 2009
Messages
19,230
check the Change Event of the 3 textbox.
 

Attachments

  • PatientsNew6.zip
    828.6 KB · Views: 203

Users who are viewing this thread

Top Bottom