thmsjlmnt3953
Registered User.
- Local time
- Today, 16:48
- Joined
- May 20, 2014
- Messages
- 120
Hi,
Im getting a data type error when i try the below and cant seem to figure it out?
Im getting a data type error when i try the below and cant seem to figure it out?
Code:
Private Sub Command2_Click()
Dim Product As String
Product = Me.txtProd.Column(1)
If MsgBox("Is Outlook Open?", vbYesNo, "Outlook") = vbYes Then
DoCmd.RunSQL "INSERT INTO tblRequestedPallets ( P_Code_Id ) " & vbCrLf & _
"SELECT tblProducts.prod_id " & vbCrLf & _
"FROM tblProducts " & vbCrLf & _
"WHERE (((tblProducts.prod_id)=[forms]![frmNavigation]![navigationsubform]![txtprod]));"
DoCmd.SendObject acSendNoObject, , , "thomas.lamont@xyz.com", , , , Product, "Test"
Else
End
End If
End Sub