Calculation on english and german Windows OS different

edited 9:44PM in FastReport 4.0
Hello to all

the following code has different results on English and German Windows versions:
void Memo159OnBeforePrint(TfrxComponent Sender)
{
        SET("eff_foc", Round( <frxUserDataSet1."ve_foc"> * 1.0E+06 / <frxUserDataSet1."meas_power_eff">));
}

<frxUserDataSet1."ve_foc"> comes from a edit field where I can enter values like "1.2" or "1,2" (Point or Comma is allowed)
<frxUserDataSet1."meas_power_eff"> is a double value

Under German Windows calculating the result with Comma-value is correct, with Point-value the result is 100 times too high
Under English Windows calculating the result with Comma-value is 100 times too low, with Point-value the result is 100 times too high

Editing DisplayFormat and Separators didn't change the effect.

I hope anyone has a solution for me.
Thanks in advance

Comments

  • gpigpi
    edited 9:44PM
    Try to convert <frxUserDataSet1."ve_foc"> to float first

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.