Decimal.Parse

Syntax

Parse(Value: String): Decimal;

Parameters

Value. The string value that must be converted into the Decimal type.

Description

The Parse method converts a string value into the Decimal type without validation.

Comments

This method does not take into account specified regional parameters. The . symbol that is used to divide integral and fractional parts of number should be used in the value passed by the Value parameter; numeric separator is not used.

If the conversion failed, an exception is thrown.

Example

Sub UserProc;
Var
    d: Decimal;
    s: String;
Begin
    s := "12345.6789";
    d := Decimal.Parse(s);
End Sub UserProc;

After executing the example the "d" variable contains the value 12345.6789.

See also:

Decimal