This in not what I am looking for. When I and the ' it only searches the
current record. I want it to search all my records but only the field
[DDLID].
I am not sure how to set the Focus to [DDLID] because when the form opens
[Caller] is the first field to be filed out.
Thanks
Jen
OK,
Would you post the code for your FIND button?
Rather than use FIND, it is easier to filter the recordset.
Like Klatuu said, you could put an unbound text box in the header of the
form and add two buttons. One button would set the filter and the other would
remove the filter.
If [DDLID] is numeric and the text box in the header is named "Text8", the
following code will show only records that match what is entered in the text
box:
(Change Text8 to the name of your text box)
' filter records
Private Sub SetFilterOn_Click()
Me.Filter = "[DDLID] = " & Me.Text8
Me.FilterOn = True
End Sub
' remove the filter
Private Sub SetFilterOff_Click()
Me.FilterOn = False
End Sub
If [DDLID] is text, use the fillowing code:
'filter records
Private Sub SetFilterOn_Click()
Me.Filter = "[DDLID] = '" & Me.Text8 & "'"
Me.FilterOn = True
End Sub
HTH

Signature
Steve S
--------------------------------
"Veni, Vidi, Velcro"
(I came; I saw; I stuck around.)
> This in not what I am looking for. When I and the ' it only searches the
> current record. I want it to search all my records but only the field
[quoted text clipped - 31 lines]
> > >
> > > Thanks Jen
Klatuu - 01 Nov 2006 15:06 GMT
Were I doing it, I would use only one button.
' filter records
Private Sub SetFilter_Click()
If Me.SetFilter.Caption = "Set Filter" Then
Me.Filter = "[DDLID] = " & Me.Text8
Me.FilterOn = True
Me.SetFilter.Caption = "Clear Filter"
Else
Me.FilterOn = False
Me.SetFilter.Caption = "Set Filter"
End If
End Sub
> OK,
>
[quoted text clipped - 68 lines]
> > > >
> > > > Thanks Jen