"Look in" limited

Kila

Registered User.
Local time
Today, 15:42
Joined
Mar 5, 2003
Messages
275
I have a simple form with a "search" button that opens the Find/Replace utility. Is there a way for the "look in" field to show ALL the fields in the form, not just the one that you selected before clicking the button.

Thanks in advance!
 
What exact code are you using? You have to have lines in your button's code that are setting the focus and then selecting a certain textbox before running the search; remove it.

BTW, usually the question we see here is just the opposite! The OPs have the code to run the check, but it's running the check against all the fields, and they only want it run against a single field!
 
Actually...

Actually, this was one of those real basic, quick fixes. This is the basic "find & replace" search box that the wizard creates when you select the option when you create a button.

I DO want it to search only in one field, but I want the "look in" drop down to allow you to select from ALL the available fields. Right now, you muct pick the field first, and THEN click the "find" button the wizard created. I think this was one of the default "address list databases that were created using a wizard, we are just adding this "find" button to one of the forms. Interestingly, When you click the "look in" field, you get to chose from the field you selected AND the address field....ALWAYS the address field. I cannot find anywhere in properties or anywhere else where this field seems special.

The user of this database is currently on the phone, so I cannot get her to e-mail me the code, but I did glance at it while I was over there. It did not seem to reference ANY limiting factors. It was basic, computer-generated code. I created a similar button at another database here on my desk, and the code behind it seems to be:

Code:
Private Sub btnFind_Click()
On Error GoTo Err_btnFind_Click


    Screen.PreviousControl.SetFocus
    DoCmd.DoMenuItem acFormBar, acEditMenu, 10, , acMenuVer70

Exit_btnFind_Click:
    Exit Sub

Err_btnFind_Click:
    MsgBox Err.Description
    Resume Exit_btnFind_Click
    
End Sub
 

Users who are viewing this thread

Back
Top Bottom