Query A Table Using A Value From A Form
Question posted by: Aric Green
(Newbie)
on
August 27th, 2008 02:38 PM
I have a form that contains customer information. I want to use the ID_NUMBER to query another table (when I click a button) to return the record that matches that ID_NUMBER. What is the easiest way to do this?
3
Answers Posted
- Create a Query based on your Customer Table.
- In the Criteria Row for the ID_NUMBER, set Criteria similar to the following:
- [Forms]![<Your Form Name>]![<Field contained ID_NUMBER>]
Thanks ADezii. That is what I was thinking but it was not working. I figured it out though. I was creating a new record on the form and using the query to append the ID NUMBER to other tables to create a record automatically on them to use later. I wasn't requerying the form and going back to the record before running the append querys so it was not creating the new record in the other tables. Now that I have figured this out I just have to write the code to do that. Again thanks.
Quote:
Originally Posted by Aric Green
Thanks ADezii. That is what I was thinking but it was not working. I figured it out though. I was creating a new record on the form and using the query to append the ID NUMBER to other tables to create a record automatically on them to use later. I wasn't requerying the form and going back to the record before running the append querys so it was not creating the new record in the other tables. Now that I have figured this out I just have to write the code to do that. Again thanks.
You are quite welcome, Aric.
|
|
|
What is Bytes?
We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights.
Get the best answers to your questions from over 197,038 network members.
Top Microsoft Access / VBA Contributors
|