Command Button to Open another form
Posted on 2008-06-23
I have attached a screen shot with the relationships of the three tables that are included in my question.
So I have a Form 1 to enter data into the four Requirements Table fields (ID is an auto-gen number)
What I want is a command button on Form 1 that will close Form 1 then open and maximize Form 2. In Form 2 I want to search through the People Table and find a record. Then I want to be able to enter in several Roles via Form 2 that will create multiple entries into the Requirements People Table. It should automatically enter in the ID that is autogenerated after creating a Requirement entry from Form 1, and it should automatically enter the unique Employee ID from the People record that you chose in Form 2. It should enter these two things into the Requirements People Table for each role (different record) that is chosen.
So my questions are, what would be the VBA code for the command button on Form 1?
How can I set up Form 2 to accomplish this feat?