Listbox selections to populate child records (1 Viewer)

bmaccess

Member
Local time
Today, 11:55
Joined
Mar 4, 2016
Messages
78
Hi there

I have this one problem that I am struggling with. I have a listbox (multi selection). The listbox contains all the subjects a school can offer. Students only take seven subjects. I would like to allocate the selected subjects to the child records by clicking a Button on the form to all the one-to-many child records at once if possible or by going to each parent and click the button then populate each child record. Currently I must go to the child record, click on a drop down list choose one subject, then I must go to the next row for the second subject, then go to the next row for the third subject until all seven has been selected. This is a very long and slow process.:( I need to do this for each learner in the one-to-many table. Please any help with VBA code in the Button that can solve this problem. Thanks
 

Attachments

  • Student_Subjects.zip
    691.9 KB · Views: 45
Last edited:

bmaccess

Member
Local time
Today, 11:55
Joined
Mar 4, 2016
Messages
78
Hi thanks for that. I will try that. Can I send you or anybody else a copy of my database for a better understanding what I require. I am struggling to upload file here.
Thanks

Much appreciated for your help
 

bmaccess

Member
Local time
Today, 11:55
Joined
Mar 4, 2016
Messages
78
Hi Paul

Thanks for your help. I first compressed it as rar file and I notice the rar was also smaller than 2Mb. I noticed rar is not part of the available files. Thanks I compressed it with built-in zip and the Student_Subjects database has been added. Can you have a look at it and see if you can find a solution for me please.

Thanks
Ben
 

pbaldy

Wino Moderator
Staff member
Local time
Today, 11:55
Joined
Aug 30, 2003
Messages
36,133
What exactly are you having trouble with?
 

bmaccess

Member
Local time
Today, 11:55
Joined
Mar 4, 2016
Messages
78
Hi Paul

Did you manage to open the database and run it? Ok, what I require is that each learner needs to be assign an amount of seven or more subjects. It is time consuming if I have to go to each learner, click on the dropbox and select the subjects one by one. So if I go to the first record I must choose the first subject. Then for the second subject I must go to the next record in the child form and choose the second subject from the list. To do this seven times for one learner is fine. But I need to do this for a whole school with a minimum total of 400 learners and can be a very boring time consuming task. What I would like to do is select the learner then with a click of a button all the subjects from the listbox must go to that learner. Then when I go to the next learner I just want to click the button and the subjects must be assign as child records to each learner.
Thanks for your help. Nowhere on the Internet I can find some solution.
I will really be happy I you can come up with some code. An even better solution will be if I can click one button and assign all the subjects to all the learners in one go.:) If you need any other information let me know.

Thanks
Ben
 

Users who are viewing this thread

Top Bottom