Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Inserting into a table using values from comboboxes

Status
Not open for further replies.

MsMope

IS-IT--Management
Sep 3, 2003
83
US
Good Morning,
I have 4 comboboxes on my form
cboEmployees
cboSystem
cboReason
cboType
these are bound to the corresponding tables with select statments ex:
Code:
SELECT Employees.EmployeeID, Employees.LastName FROM Employees;

I have another table called ChangeDetails, this tables stores the ID values from the 4 other tables, a DateChange, and Details field.

I have a button on my form btnAddRecord that when clicked I want it to append a record into the ChangeDetails table using the ID fields from the comboboxes, today's date and the text from the textbox on the form(details column), but I am unsure how to reference the ID fields from the combo boxes. Any suggestions?
 
you should be able to reference the id field of comboboxes by:

cboEmployees.column(0)



- RoppeTech
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top