Need some help with this.
I'm working on a library database search form with a bunch of different fields, Title, Author, Publisher etc. Users can search by one or more fields - Access ignores whatever fields are left blank on the search form.
I'm trying to set it up so that users can search the Title field with wildcards. Right now they are required to submit their search criteria enclosed in asterisks, and this works. However, I think it would be 'cleaner' to have a separate field where users could just enter their search criteria and let Access take care of the asterisks.
How to build this in to the script?
Here what I've got so far:
<snip>
where = where & " AND [Title] = '" + Me![titlekeyword] + "'"
</snip>
[Title] is the name of the field in the queried table; [titlekeyword] is the name of the field in the searchform.
If someone could let me know how to stick the asterisks into this script I would really appreciate it. Thanks in advance.
I'm working on a library database search form with a bunch of different fields, Title, Author, Publisher etc. Users can search by one or more fields - Access ignores whatever fields are left blank on the search form.
I'm trying to set it up so that users can search the Title field with wildcards. Right now they are required to submit their search criteria enclosed in asterisks, and this works. However, I think it would be 'cleaner' to have a separate field where users could just enter their search criteria and let Access take care of the asterisks.
How to build this in to the script?
Here what I've got so far:
<snip>
where = where & " AND [Title] = '" + Me![titlekeyword] + "'"
</snip>
[Title] is the name of the field in the queried table; [titlekeyword] is the name of the field in the searchform.
If someone could let me know how to stick the asterisks into this script I would really appreciate it. Thanks in advance.