Hi,
I have a form where I'd like a user to be able to enter some data and have it pull up related records based on what was entered. For instance, if I have an inventory of products dealing with fruit, my data would look something like this:
item
----
Apple Sauce
Apple Cider
Orange Juice
Apple Juice
Apple Tarts
Orange Peels
etc.
Now I want the user to be able to enter "apple" into a text box for it to pull up all records starting with "Apple". I have some VBA code that will let me do this (from the Access Modules FAQ), but I'm not sure how to implement it. I was thinking of using a text box and putting a command button next to it to run the code. The only thing is I don't know how to pass the contents of the text box into a variable that the button code could have access to. Any help is appreciated.
I have a form where I'd like a user to be able to enter some data and have it pull up related records based on what was entered. For instance, if I have an inventory of products dealing with fruit, my data would look something like this:
item
----
Apple Sauce
Apple Cider
Orange Juice
Apple Juice
Apple Tarts
Orange Peels
etc.
Now I want the user to be able to enter "apple" into a text box for it to pull up all records starting with "Apple". I have some VBA code that will let me do this (from the Access Modules FAQ), but I'm not sure how to implement it. I was thinking of using a text box and putting a command button next to it to run the code. The only thing is I don't know how to pass the contents of the text box into a variable that the button code could have access to. Any help is appreciated.