TTMSFNCDataGrid.ValueToInteger Method
Converts a cell value to an Integer without raising an exception.
API unit family: TMSFNCDataGrid
Declaring type: TTMSFNCDataGrid
Inherited from: TTMSFNCCustomDataGrid
Overloads
Overload 1
Converts a cell value to an Integer without raising an exception.
function ValueToInteger(AValue: TTMSFNCDataGridCellValue): Integer; overload;
int __fastcall ValueToInteger(const TTMSFNCDataGridCellValue &AValue)/* overload */;
Parameters
| Name | Description |
|---|---|
AValue |
The cell value to convert. |
Returns
The value converted through ValueToInt64 and truncated to Integer.
Overload 2
Converts a cell value to an Integer using the specified format settings, without raising an exception.
function ValueToInteger(AValue: TTMSFNCDataGridCellValue; AFormatSettings: TFormatSettings): Integer; overload;
int __fastcall ValueToInteger(const TTMSFNCDataGridCellValue &AValue, const System::Sysutils::TFormatSettings &AFormatSettings)/* overload */;
Parameters
| Name | Description |
|---|---|
AValue |
The cell value to convert. |
AFormatSettings |
Format settings used to parse floating-point strings. |
Returns
The integer value, or 0 when the value is empty, unparsable or outside the Integer range.