Hi
I am trying to update a table with data selected from a list box, I have tried the code below with out success, can any one help.
Thanks in advance...........
Dim strCriteria As String
Dim varItem As Variant
Dim strSQL As String
For Each varItem In Me!lsthold.ItemsSelected
strCriteria = strCriteria & ",'" & Me!lsthold.ItemData(varItem) & "'"
Next varItem
DoCmd.RunSQL "INSERT INTO tblQuote ([Product_Code],[Description]) VALUES (Criteria);"
I am trying to update a table with data selected from a list box, I have tried the code below with out success, can any one help.
Thanks in advance...........
Dim strCriteria As String
Dim varItem As Variant
Dim strSQL As String
For Each varItem In Me!lsthold.ItemsSelected
strCriteria = strCriteria & ",'" & Me!lsthold.ItemData(varItem) & "'"
Next varItem
DoCmd.RunSQL "INSERT INTO tblQuote ([Product_Code],[Description]) VALUES (Criteria);"