F_RoundLREAL_EX
Application
The function F_RoundLREAL_EX rounds the input variable lrIN of the data type LREAL to the number of decimal places specified by iPrecision. This function can also be used for REAL data types. An instance of the function LTRUNC from the library TcMath.lib is used internally in the function.
VAR_INPUT
lrIN : LREAL;
iPrecision : INT; 0..5
lrIN: floating point number that is to be formatted.
- If lrIN < 0.1 AND lrIN >= 0.05, then the return value of the function is 0.1 |
iPrecision: precision. The value determines the number of digits after the decimal point. The range of decimal places begins with 0 and ends with 5.