I have another question for you. My database is used to
track circuits that have been research and it is sorted
by the project name. When new circuits are uploaded to
the database they do not have and project associated to
them. I have added New Circuits and All circuits to my
combo box now how can i modify the code to make it sort
by all null record and all records?
I REALLY appreciate all you help
Raj
-----Original Message-----
Allen,
Work perfect!!
Thank you!!
-----Original Message-----
Replace txtFindSurname with the name of your combo.
Put
square brackets
around the name it it contains a space.
If the Bound Column of the combo is a Number field,
omit
the extra quotes.
--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users -
http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.
message
Allen,
I don't mean to get in the middle of you'll
conversation. I have been looking for code like this
for
over a month and its works great. I would like to
modify
it a little I am trying to using this code with a
combo
box. I placed the code in the AfterUpdate and I get
is a
pop up asking for me to enter the project name. How
can
I alter it code so that the choice from the combo box
is
what it will use.
Thank you very much
Raj
-----Original Message-----
John, I think you want to place an unbound text box
on
the form (in Form
Header section perhaps?), along with a command
button.
User enters
something, and then you find the records that have
that
in a particular
field (such as surname).
If that's the idea, and their could be several
possible
matches, the best
idea might be to filter the form so it shows only the
matches.
Private Sub cmdFilter_Click()
Dim strWhere As String
Dim lngLen As Long
If Me.Dirty Then 'Save before filter
Me.Dirty = False
End If
If Not IsNull(Me.txtFindSurname) Then
strWhere = strWhere & "([Surname] = """ & _
Me.txtFindSurname & """) AND "
End If
If Not IsNull(Me.txtFindFirstName) Then
strWhere = strWhere & "([FirstName] = """ & _
Me.txtFindFirstName & """) AND "
End If
'etc for other search boxes.
lngLen = Len(strWhere) - 5 'Without trailing "
AND ".
If lngLen <= 0 Then
MsgBox "No criteria."
Else
Me.Filter = Left(strWhere, lngLen)
Me.FilterOn = True
End If
End Sub
What is the procedure for setting up search
capabilities
on a form? I have set up a command button but
cannot
get
the code right on the "click"
Can you search through Pages?
.
.