G
Guest
Didn't know which area to post this so I chose here!
I have a form in which there are 3 ComboBoxes, 1 Textbox and a CommandButton.
Each ComboBox has items out of different tables: a manufacturer table, a
product type table and a usage table. They are there to choose each of the
previous, type a product name into the textbox and then click the
CommandButton "Add Record" to add this info into yet another table that is a
complete catalogue of manufacturers, products and product usage.
Sound good in theory, right? Well, it would if it worked! The trouble is it
doesn't do anything when I click the button. Could someone review this and
help out? Thanks in advance! Here's my code:
'================================
Option Compare Database
Private Sub add_data_Click()
On Error GoTo Err_add_data_Click
DoCmd.OpenTable "vList", , acAdd
'===I think I need more code here==='
Exit_add_data_Click:
Text7.Text = ""
Text7.SetFocus
Exit Sub
Err_add_data_Click:
MsgBox Err.Description
Resume Exit_add_data_Click
End Sub
I have a form in which there are 3 ComboBoxes, 1 Textbox and a CommandButton.
Each ComboBox has items out of different tables: a manufacturer table, a
product type table and a usage table. They are there to choose each of the
previous, type a product name into the textbox and then click the
CommandButton "Add Record" to add this info into yet another table that is a
complete catalogue of manufacturers, products and product usage.
Sound good in theory, right? Well, it would if it worked! The trouble is it
doesn't do anything when I click the button. Could someone review this and
help out? Thanks in advance! Here's my code:
'================================
Option Compare Database
Private Sub add_data_Click()
On Error GoTo Err_add_data_Click
DoCmd.OpenTable "vList", , acAdd
'===I think I need more code here==='
Exit_add_data_Click:
Text7.Text = ""
Text7.SetFocus
Exit Sub
Err_add_data_Click:
MsgBox Err.Description
Resume Exit_add_data_Click
End Sub