I'm in the process on developing this database and am stuck at a certain point despite trying for a whole day. I'm very new to access and this is my first database.
I have this form called frmPatient which is used to enter baseline data about patients and a form called frmVisit which is used to enter visit details of a patient at each visit. The frmVisit form also has a subform frmIxResults.
On the frmPatient I have a command button set up to start a new visit and a combobox which is used to view / edit previous visits. Both use frmVisit form. With this setting i can enter new visit data into frmVisit as long as I don't try to enter data into the subform (subform dataentry set to yes). When I try to do this I get an error "you can't assign a value to this object" and when I try to move out of the subform I get an error "you must enter a value in the 'tblVisit.PatientID' field". But when I check the particular table, is already has this visit recorded. When I exit out of the form frmVisit and go into the particular visit from the combobox, I can then enter the subform and enter data.
I have tried a lot of things including setting data entry property of frmVisit to both yes and no but face with the same error irrespective of this setting.
I have attached the DB below.
I would be thankful for any suggestions.
I have this form called frmPatient which is used to enter baseline data about patients and a form called frmVisit which is used to enter visit details of a patient at each visit. The frmVisit form also has a subform frmIxResults.
On the frmPatient I have a command button set up to start a new visit and a combobox which is used to view / edit previous visits. Both use frmVisit form. With this setting i can enter new visit data into frmVisit as long as I don't try to enter data into the subform (subform dataentry set to yes). When I try to do this I get an error "you can't assign a value to this object" and when I try to move out of the subform I get an error "you must enter a value in the 'tblVisit.PatientID' field". But when I check the particular table, is already has this visit recorded. When I exit out of the form frmVisit and go into the particular visit from the combobox, I can then enter the subform and enter data.
I have tried a lot of things including setting data entry property of frmVisit to both yes and no but face with the same error irrespective of this setting.
I have attached the DB below.
I would be thankful for any suggestions.