The default forms search box...customized? (1 Viewer)

PaulWilson

Registered User.
Local time
Today, 06:42
Joined
May 19, 2011
Messages
43
The default search box that comes with Access forms works well enough for my users. The only trouble is that it's hidden down there at the bottom of the form and is rather small. A cosmetic problem.

Is it not possible to add a control (call it txtMySearchBox) on a form and point it to the deafult search box that Microsoft provides? When you type something into txtMySearchBox it ends up in the default search box. Can one get at the default search box via code?

If not is there a bit of vba that mimics the behavior of the default form search?

I've seen other query-parameter based examples that work off the onChange event. They work dang well, but I need something I can drop on any form with no added fuss.

Just wondering...
 

GinaWhipp

AWF VIP
Local time
Today, 06:42
Joined
Jun 21, 2011
Messages
5,899
There is nothing I know of that you can drop on your form with no added fuss. No matter what it is going to require code, something like...

Code:
'In the After_Update of YourtxtFilter field OR on a Command button
 
Me.Filter = "YourField1 Like '*" & Me!YourtxtFilter & "*' OR " & _
"YourField2 Like '*" & Me!YourtxtFilter & "*'" & " OR " & _
"YourField3 Like '*" & Me!YourtxtFilter & "*'"
Me.FilterOn = True

Then you can type in YourtxtFilter field and get returns to show. But without knowing how your form is set up hard to know if they above will work the way you want.
 

PaulWilson

Registered User.
Local time
Today, 06:42
Joined
May 19, 2011
Messages
43
What a novel idea...filters. Hadn't seen that one, but it's a good idea!

I now have a dialog that comes up when my users click on my search button directing them to a short tutorial on the use of the binoculars. That search feature is very rich and if it's there why should I recreate the wheel?
 

GinaWhipp

AWF VIP
Local time
Today, 06:42
Joined
Jun 21, 2011
Messages
5,899
Hmmm, I rarely use the Search but that is another good one! See you just needed a jump start! :D
 

Users who are viewing this thread

Top Bottom