Decimal symbol

Results 1 to 2 of 2

Thread: Decimal symbol

  1. #1
    Janez Guest

    Default Decimal symbol

    Hi! I have a problem with users regional settings for decimal place. <BR>In my form I take a value in string format, then I clean it with cdbl function and then I put it in SQL Update statement:<BR>strSQL = "UPDATE TableA SET Field1 = " & cdbl(FormField1,2), Field2 = ....<BR><BR>If user have decimal delimiter set to "." (dot) result is OK. Some of my users came from countries where delimiter is set to ","(comma). In this case SQL String isn&#039;t correct. I fixed this problem with replacing comma to dot ( Rsql = Rsql & " SET PE1 = " & replace(cdbl(RFPE1.value),",",".") ), but I think, that this is not universal solution. <BR>Any ideas?<BR><BR><BR><BR><BR><BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Decimal symbol

    Your only other option is to get the users to tell you which country they are in, and then set the LCID to the correct one for that country.<BR><BR>E.g If they are in France, Session.LCID=1036 will make the system work with French style numbers (i.e. ten thousand = 10.000)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts