Following code just show decimals


Hi,

I'm trying to update an Access database with following code:

strSQLUpdate = "UPDATE ThreeYears Set AvgIndex= Format(" & dblIndexOne & ", ""0.00"") WHERE ProduktNr=" & "'" & strTYProd & "' AND Month=" & "'" & strMonthTY & "'"

dblIndexOne should be 0.70 but when I check in the Access database the result is 70, only the decimals.
If I step through the lines so I can see that dblIndexOne shows the numbers with comma instead of full stop 0,70 instead of 0.70.

thanks for your help!

If you enjoyed this post, subscribe for updates (it's free)

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.
  • You can enable syntax highlighting of source code with the following tags: <code>, <blockcode>. The supported tag styles are: <foo>, [foo].

More information about formatting options

Type the characters you see in this picture. (verify using audio)
Type the characters you see in the picture above; if you can't read them, submit the form and a new image will be generated. Not case sensitive.