Keep data when creating a new record.

rgreene

Registered User.
Local time
Today, 04:55
Joined
Jan 22, 2002
Messages
168
Hello All,

I'm working on a database for a local youth shelter. I have a form where I enter the youths info (name, age, date of birth.stuff like that). This info will remain constant for the youth (except the age) That way if the youth end up back in the shelter they don't have to reenter this info. So I either enter a new youth on the frmResidents or I bring up the record for the youth. From here I go to an Admissions form (frmAdmissions). I have a button on the frmResidents that on click goes to the frmAdmissions and carries over the youths name. The problem is that if the youth has been in the shelter before it bring up the record for the youth. I would like it to carry over the youths name but everything else in the record be blank. If I create a new record then all the fields go blank including the youths name.

Any suggestions?

Thanks,
Rick
 
You need to restructure your database just a bit. Since a youth can be in the shelter more than one time you want the Admissions table to be the Many side in a One to Many relationship between the Residents table and the Admissions table.

tblResidents
ResidentID (Primary Key and Autonumber)
LastName
FirstName
...other fields

tblAdmissions
AdmissionsID (Primary Key and Autonumber)
ResidentID (Foreign Key and Long Integer)
AdmissionsDate
...other fields

Make the frmAdmissions a subform to the form frmResidents and you should be good to go...

hth,
Jack
 
My Admissions table and Residents table is a 1 to Many relationship.
I really can't make a subform because I have to much data on the form. No place to put the subform, which also contains a bunch of fields.
 
You could create a Tab control and place the data on separate tabs or a page break and show the data on two pages. You could also pop up a form with the subform data as well..

hth,
Jack
 
rgreene,

Check out my attached sample and see how I am duplicating the current record in formA and creating a new record in formB with the data from the current record in formA.

HTH
 

Attachments

Users who are viewing this thread

Back
Top Bottom