none
MS Access - Form - Junction table form , M-M Relationship RRS feed

  • Question

  • Hi,

    I have a main form that is linked with a table called "Source". Then there is subform linked with Junction table (tblSourcetoCountry).  In the subform there is list box to select multiple values. When i select multiple values it is not taking ID. Can anyone let me know how can i make it work? (The idea behind this is that for single source i want to select multiple Country and Region) 

    Posted is a sample DB on link (https://1drv.ms/u/s!Aon_FQmk7bYmiS1m0p4slNRyRuWy) , where the form "frmSource" is having this issue.

    Any help would be appreciated.

    Thank you.
    Sunday, September 24, 2017 8:41 AM

All replies

  • Instead of multi-select list boxes, use combo boxes, and create a separate record for each combination of values.

    Regards, Hans Vogelaar (http://www.eileenslounge.com)

    Sunday, September 24, 2017 9:55 AM
  • Hi Wsm93,

    Thanks for sharing the file. I have downloaded it and could reproduce your issue.

    After checking the Source setting of the combo box, I'm wondering why do you set RowSource "SELECT tblCountry.ID, tblCountry.Country FROM tblCountry;" but set Control Source "Countro_ID"? Countro_ID is not one of the fields in Row Source. I'm wondering what do you want to do via this form.

    After moving Control Source "Countro_ID", it works without error.

    Best Regards,

    Terry


    MSDN Community Support Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Monday, September 25, 2017 7:57 AM