D
Daniel
I am trying to make a procedure that brings up an
appointment when the user enters any part of the ApptID.
I have an unbound field and a button. I am having trouble
coding the 'any part' part. I have tried to make an SQL
statement and then set the Form.RecordSource to that
statement but it does not seem to want to work.
Any suggestions?
Here is the SQL statement that I have:
ApptIDSQL = "SELECT tAppt.fApptID FROM tAppt " & _
"WHERE ((tAppt.fApptID) LIKE '*' & '" & Trim(Me!
txtApptID) & "' & '*')"
DoCmd.OpenForm "frmAppt", , , Form.RecordSource =
ApptIDSQL, acFormEdit
In addition can I set the recordsource from the
DoCmd,OpenForm Where statement? Or can I only do that on
the Load event of the form?
Thanks
Dan
appointment when the user enters any part of the ApptID.
I have an unbound field and a button. I am having trouble
coding the 'any part' part. I have tried to make an SQL
statement and then set the Form.RecordSource to that
statement but it does not seem to want to work.
Any suggestions?
Here is the SQL statement that I have:
ApptIDSQL = "SELECT tAppt.fApptID FROM tAppt " & _
"WHERE ((tAppt.fApptID) LIKE '*' & '" & Trim(Me!
txtApptID) & "' & '*')"
DoCmd.OpenForm "frmAppt", , , Form.RecordSource =
ApptIDSQL, acFormEdit
In addition can I set the recordsource from the
DoCmd,OpenForm Where statement? Or can I only do that on
the Load event of the form?
Thanks
Dan