Access2000
I am trying to create a multiple field filter using vba. I would like to include the Like * on the front end of the 2nd and 3rd criteria so that if a user does not include an option for field 2 or field 3 the filter will show all results for field 1
Here is what I have that works so far. Where supplier is a number.
DoCmd.ApplyFilter "", "[supplier] = " & Me.[Combo95]
I get into trouble when I try to add another field to the string like this. I think I need an ampersand and probably some more quotes but I can't figure out where. I would also like to include a Like "*" in front of
I am trying to create a multiple field filter using vba. I would like to include the Like * on the front end of the 2nd and 3rd criteria so that if a user does not include an option for field 2 or field 3 the filter will show all results for field 1
Here is what I have that works so far. Where supplier is a number.
DoCmd.ApplyFilter "", "[supplier] = " & Me.[Combo95]
I get into trouble when I try to add another field to the string like this. I think I need an ampersand and probably some more quotes but I can't figure out where. I would also like to include a Like "*" in front of
Code:
if possible. [code] is also a numeric field. I can only imagine how complicated this would be if it was text! Any help would be greatly appreciated.
DoCmd.ApplyFilter "", "[supplier] = " & Me.[Combo95]_
And & "code = " & Me.[combo98]