A
anthony.pierdominici
I have been searching for the answer to this and can't seem to find
it.
I am trying to apply a filter to a recordset in VBA and it works
perfectly except for when one of the conditions is a wildcard.
Example:
frmFilter has a number of combo boxes from which the user can specify
criteria that will be used in the filter. So say cboName = "*" and my
filter string is is something like this:
[Name] Like '*'
This returns no records...
I have also tried to make the string like this:
[Name] Like "*"
But that doesn't work either.
The first example (using Like with single quotes) seems to work for
everything except when the only thing in the combo box is the
asterisk. If I put any character and an asterisk (ex. D*) in the
combo box it will return records.
Anyone have any ideas on how to fix this?
Thanks,
Anthony Pierdominici
it.
I am trying to apply a filter to a recordset in VBA and it works
perfectly except for when one of the conditions is a wildcard.
Example:
frmFilter has a number of combo boxes from which the user can specify
criteria that will be used in the filter. So say cboName = "*" and my
filter string is is something like this:
[Name] Like '*'
This returns no records...
I have also tried to make the string like this:
[Name] Like "*"
But that doesn't work either.
The first example (using Like with single quotes) seems to work for
everything except when the only thing in the combo box is the
asterisk. If I put any character and an asterisk (ex. D*) in the
combo box it will return records.
Anyone have any ideas on how to fix this?
Thanks,
Anthony Pierdominici