A
Alan
I have an Access 2002 database with the following tables/fields:
tblStudents
---------------
StuID (key)
Name
Address
Children? (yes/no field)
ClassNo
tblChildren
--------------
StuID
ChildNo (key is StuID + ChildNo)
Name
DOB
I have a form named frmAddStudents where the user can input new
Student info. If the user answers yes in the Children? field, I want
to insert code at the proper event for that field that will open my
frmAddChildren form, have the StuID control on that form already set
to the value of StuID that was entered on the frmAddStudents form, and
move the focus to the ChildNo control for input. If the user answers
no in the Children? field, I want the focus to jump to the ClassNo
control on the frmAddStudents. Can someone provide me with the
appropriate code that will accomplish this?
At the end of the frmAddChildren, I will have two command buttons. The
first will be to Add Another Child. For the click event of this cmd
button, I need code that will save the record just entered to the
tblChildren table and then start a new record on the frmAddChildren
with the focus set at the ChildNo control and the StuId control
already set to equal the value from the previous record.Can someone
provide me with the appropriate code that will accomplish this?
Thanks for your assistance.
Alan
tblStudents
---------------
StuID (key)
Name
Address
Children? (yes/no field)
ClassNo
tblChildren
--------------
StuID
ChildNo (key is StuID + ChildNo)
Name
DOB
I have a form named frmAddStudents where the user can input new
Student info. If the user answers yes in the Children? field, I want
to insert code at the proper event for that field that will open my
frmAddChildren form, have the StuID control on that form already set
to the value of StuID that was entered on the frmAddStudents form, and
move the focus to the ChildNo control for input. If the user answers
no in the Children? field, I want the focus to jump to the ClassNo
control on the frmAddStudents. Can someone provide me with the
appropriate code that will accomplish this?
At the end of the frmAddChildren, I will have two command buttons. The
first will be to Add Another Child. For the click event of this cmd
button, I need code that will save the record just entered to the
tblChildren table and then start a new record on the frmAddChildren
with the focus set at the ChildNo control and the StuId control
already set to equal the value from the previous record.Can someone
provide me with the appropriate code that will accomplish this?
Thanks for your assistance.
Alan