Comma instead of dot in CEdit

 

In CEdit i can write a decimal number with a dot (for example 0.1) and it works without a problem, but if I write the same with a comma instead of a dot (0,1), CEdit cannot read it.

I have a reason, why i need to use a comma instead of a dot, but i don't know how to do it. Does anyone please know how to do this?

Thank you

 
Jan Naj:

In CEdit i can write a decimal number with a dot (for example 0.1) and it works without a problem, but if I write the same with a comma instead of a dot (0,1), CEdit cannot read it.

I have a reason, why i need to use a comma instead of a dot, but i don't know how to do it. Does anyone please know how to do this?

Thank yo worku

Setting the text on a CEdit object takes a string argument, so I don't see why it wouldn't work.

Before anything, convert the decimal number to a string using DoubleToString.

Then, use StringReplace to change the period to a comma.

 
Alexander Martinez #:

Setting the text on a CEdit object takes a string argument, so I don't see why it wouldn't work.

Before anything, convert the decimal number to a string using DoubleToString.

Then, use StringReplace to change the period to a comma.

That's right, it works.
You are great, thank you very much.
Reason: