Subform opening as new record

Kuleesha

Member
Local time
Today, 20:18
Joined
Jul 18, 2021
Messages
50
I have attached my database below.
The frmPatients for has a toggle which brings up frmVisit. This form had a subform under investigation results tab page. I have set the frmVisit to automatically create a new visitID when i type in details.
When I enter data into the subform I need this to go under the same visitID as the parent form. But this data is recorded under a vew vistID instead.
What am I doing wrong ?
 

Attachments

Thanks for your suggestion. I am creating my first database and your suggestions are extremely helpful.
I changed the code i had set to execute on clicking tabcontrol as a Sub Form BeforeInsert event.
But the primary problem of inability to enter data into the same visitID on the subform still persist.
I have attached the modified version below.
 

Attachments

Thank you for your comments.
1 & 2 - problem solved. Thanks
3. I am not planning to enter new records directly into investigation results subform. It is meant to be used only for the record indicated in the parent form
4. I actually do not want to analyse this data. I just need to keep record and print it out as a report for each and every record seperately (each record is for a patient and i just need the details on a single visit record to be printed at one time)
PastMxHx means past medical history :)
 
Have you finished this project?

If not...I would use a normal button to open the visit form, pass the patient ID to that form in the open command. Delete the extra patient ID and visit fields on the investigation sub form. And calculate the age from the date of birth.
 

Users who are viewing this thread

Back
Top Bottom