I am trying to lookup the second column in a combo box to auto fill a form using the AfterEvent Update
Me.VendeurID = Me.PickCombo.Column(0)
Me.FirstName = Me.PickCombo.Column(2)
Me.Emailtxt = DLookup("", "[Vendeurs]", "VendeurID = " & Me.VendeurID)
Me.Equipetxt = DLookup("[equipe]", "[Vendeurs]", "VendeurID = " & Me.VendeurID)
Me.Phonetxt = DLookup("[business phone]", "[Vendeurs]", "VendeurID = " & Me.VendeurID)
Me.mobtxt = DLookup("[mobile phone]", "[Vendeurs]", "VendeurID = " & Me.VendeurID)
Me.notestxt = DLookup("[notes]", "[Vendeurs]", "VendeurID = " & Me.VendeurID)
The Me.Equipetxt is the problem. The Equipe Field on the Vendurs form is a combo box (from another table)
Equipe Table
Primary Key - auto Number
Equipe - Txt
No problem linking this into the Vendeurs table
The form however for the Me.Equipetxt box is using hte primary key, how can I get it to select the column(2) From the Equipe Field on the Vendeurs tbl?
Me.VendeurID = Me.PickCombo.Column(0)
Me.FirstName = Me.PickCombo.Column(2)
Me.Emailtxt = DLookup("", "[Vendeurs]", "VendeurID = " & Me.VendeurID)
Me.Equipetxt = DLookup("[equipe]", "[Vendeurs]", "VendeurID = " & Me.VendeurID)
Me.Phonetxt = DLookup("[business phone]", "[Vendeurs]", "VendeurID = " & Me.VendeurID)
Me.mobtxt = DLookup("[mobile phone]", "[Vendeurs]", "VendeurID = " & Me.VendeurID)
Me.notestxt = DLookup("[notes]", "[Vendeurs]", "VendeurID = " & Me.VendeurID)
The Me.Equipetxt is the problem. The Equipe Field on the Vendurs form is a combo box (from another table)
Equipe Table
Primary Key - auto Number
Equipe - Txt
No problem linking this into the Vendeurs table
The form however for the Me.Equipetxt box is using hte primary key, how can I get it to select the column(2) From the Equipe Field on the Vendeurs tbl?