If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Form based on Many-to-Many Relationship
I am trying to create a form based on a Many-to-Many relationship to enter
data into two tables. The table names are tblUser, tblGroup, tblJunction. tblJunction has the primary keys of tblUser and tblGroup in it. The purpose of the form is to be able to add a user to an already existing group that is populated within the tblGroup. I am able to create the form but I am not able to see any existing users or groups that are in the tables and when I add either a new user or group the information is not saved to the table. Any help that can be provided is greatly appreciated. |
#2
|
|||
|
|||
Create a form/subform. Base the main form on TblGroup and the subform on
TblJunction. Set LinkMaster/LinkChild to GroupID. Use a combobox to select a user from TblUser. The combobox needs to be designed to have a value of UserID. Write a procedure for the NotInList event to be able to add new users to TblUser or use a command button to open a data entry form to add new users. For the latter you will need to requery the combobox after add a new user to make that user appear in the drop down list. -- PC Datasheet Your Resource For Help With Access, Excel And Word Applications www.pcdatasheet.com "Jerome" wrote in message news I am trying to create a form based on a Many-to-Many relationship to enter data into two tables. The table names are tblUser, tblGroup, tblJunction. tblJunction has the primary keys of tblUser and tblGroup in it. The purpose of the form is to be able to add a user to an already existing group that is populated within the tblGroup. I am able to create the form but I am not able to see any existing users or groups that are in the tables and when I add either a new user or group the information is not saved to the table. Any help that can be provided is greatly appreciated. |
#3
|
|||
|
|||
Thank you for the help. That worked just fine. I couldn't find any
references to LinkMaster/LinkChild? But, I just created the combo box on the subform and everything appears to be running fine. Thanks again. "PC Datasheet" wrote: Create a form/subform. Base the main form on TblGroup and the subform on TblJunction. Set LinkMaster/LinkChild to GroupID. Use a combobox to select a user from TblUser. The combobox needs to be designed to have a value of UserID. Write a procedure for the NotInList event to be able to add new users to TblUser or use a command button to open a data entry form to add new users. For the latter you will need to requery the combobox after add a new user to make that user appear in the drop down list. -- PC Datasheet Your Resource For Help With Access, Excel And Word Applications www.pcdatasheet.com "Jerome" wrote in message news I am trying to create a form based on a Many-to-Many relationship to enter data into two tables. The table names are tblUser, tblGroup, tblJunction. tblJunction has the primary keys of tblUser and tblGroup in it. The purpose of the form is to be able to add a user to an already existing group that is populated within the tblGroup. I am able to create the form but I am not able to see any existing users or groups that are in the tables and when I add either a new user or group the information is not saved to the table. Any help that can be provided is greatly appreciated. |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Populate fields in Form Header based on header fields in startup f | Pat Dools | Using Forms | 0 | January 7th, 2005 03:19 PM |
Dates in a listbox connected to a form... | RusCat | Using Forms | 13 | November 25th, 2004 02:31 AM |
Can't enter data in a form based on a query | Susan L | Using Forms | 8 | November 9th, 2004 12:24 AM |
Create a Search Form and Generate a Report based on the Search Form | ace | General Discussion | 2 | November 4th, 2004 04:07 AM |
Report Based Upon Parameter Query with Form References | Vincent DeLuca | Setting Up & Running Reports | 4 | July 19th, 2004 01:55 AM |