Sign for Comma

ta5ta5 Member Posts: 1,164
Hi
I want to replace the dot (.) with a Comma (,) with format function.
This should imho work, but it does not. Can anybody point me in the right direction?
mydec := 65310.289;
MESSAGE(FORMAT(mydec,0,'<Sign><Integer Thousand><Comma,,><Decimals>'));
// should result in 65'310,289 
I'm aware that the decimal separator is set in the windows Settings, but for a special Export we weed the comma...

Thanks in advance
Thomas

Answers

  • SNielsenSNielsen Member Posts: 37
    Thomas, i think the attribute you are looking for is "1000Character"
  • vaprogvaprog Member Posts: 1,141
    Try
    FORMAT(mydec,0,'<Sign><Integer Thousand><Decimals><Comma,,>')
    
    I have never found anything other than try and error to find a working position for <Attribute> terms in a format string. Can anybody shed some light?
    Attributes that modify a certain <Field> given in the string, seem to need to follow the field immediately, though.
  • ta5ta5 Member Posts: 1,164
    Thanks Vaprog and SNielsen!

    @Vaprog: Good hint, it works your way :thumbsup: , although it's a mystery why the comma keyword comes at the end.
    FORMAT(mydec,0,'<Sign><Integer Thousand><Decimals><Comma,,>')
    

    @SNielsen: 1000Character imho is used to separate big numbers into chunks of three, for example 1'000'000.

    Regards
    Thomas
Sign In or Register to comment.