AlexN
Registered User.
- Local time
- Today, 18:40
- Joined
- Nov 10, 2014
- Messages
- 302
Hi everybody,
I use this line of code to insert records in a table
When Amount is integer everything works perfectly alright, but when Amount is decimal, code does not execute and I get the error message "Number of query values and destination fields are not the same". Needless to mention that Amount field is defined as currency with two decimal digits.
Any ideas?
Thank you
I use this line of code to insert records in a table
Code:
CurrentDb.Execute "INSERT INTO tblTransactions ([Account1ID], [Account2ID], [TransactionDate], [TransactionType], [TransactionCategory], [Amount])" & _
" VALUES ( " & Me.[Account2ID] & " , " & Me.[Account1ID] & " , #" & Format(Me.[TransactionDate], "mm/dd/yyyy") & "# , '" & Me.[TransactionType] & "', '" & "Transfer From" & "' , " & Me.[Amount] & ") ; "
Any ideas?
Thank you