G
Guest
I am extremely green with coding. I have a form/subform that I need the user
to be able to click on the Find Button and have a Search Form open (done)
where they can type in all or part of any number of fields (18 search fields)
and a list of available records will appear in list box and the user can
double click on the correct one to go to that record.
I have searched everywhere on the internet and finally found a free download
that does exactly that so I copied the code and changed all the fields to
reflect what is in my database. It doesn't work! When I debug, I am having
problems with these two lines:
'Remove the last AND from the SQL statement
strWhere = Mid(strWhere, 1, Len(strWhere) - 18)
'Pass the SQL to the RowSource of the listbox
Me.List_Results.RowSource = strSQL & " " & strWhere & "" & strOrder
I'm hoping an expert may be able to tell me, is there an error here, or is
there another way of doing this? Thank you!
to be able to click on the Find Button and have a Search Form open (done)
where they can type in all or part of any number of fields (18 search fields)
and a list of available records will appear in list box and the user can
double click on the correct one to go to that record.
I have searched everywhere on the internet and finally found a free download
that does exactly that so I copied the code and changed all the fields to
reflect what is in my database. It doesn't work! When I debug, I am having
problems with these two lines:
'Remove the last AND from the SQL statement
strWhere = Mid(strWhere, 1, Len(strWhere) - 18)
'Pass the SQL to the RowSource of the listbox
Me.List_Results.RowSource = strSQL & " " & strWhere & "" & strOrder
I'm hoping an expert may be able to tell me, is there an error here, or is
there another way of doing this? Thank you!