Helo! How could i make that all nubers are printed out with two decimal places like: 123.3 would be printed 123.30 or 123.456 would be printed 123.45 or 123 would be printed 123.00 Is there a function in C/AL that adds zeros to decimal places if there aren’t enough of them. ROUND only cuts them off if there are too many of them… pls help… lp John

Set the DecimalPlaces property of TextBox to 2:2

Unless it’s a price field. Then you have to use the properties AutoFormatType ans AutoFormatExpr. Open the sales line to see a sample of this.

Yes i tried that but that only works if you pull data(numbers) directly from a table. I pull data from table to a variable and then if there are too many decimals i round the number to two decimals but if the number has less than two decimals i’d like to add zeros in the decimals that are missing…

You can try to use FORMAT in SourceExpr like this: Amount: Decimal FORMAT(Amount,9,’<Precision,2:2><Standard Format,1>’)

Yesssss thank you, I was trying to use FORMAT but i didn’t know how exactly… thnx again

Keep in mind that parameter “9” is length of string that FORMAT returns [;)]