IDataValueConverter.TryConvert(Object, Int32, out CellValue) Method
Converts data being imported to the cell value.
Namespace: DevExpress.Spreadsheet
Assembly: DevExpress.Spreadsheet.v24.1.Core.dll
NuGet Package: DevExpress.Spreadsheet.Core
Declaration
Parameters
Name | Type | Description |
---|---|---|
value | Object | An object that is the data being imported to a cell. |
index | Int32 | An integer that is the index of the column in the data source. |
result | CellValue | A CellValue object that is the value which will be inserted in a cell. |
Returns
Type | Description |
---|---|
Boolean | true, if a conversion is successful; otherwise, false. |
Remarks
When importing data to a worksheet, you can use the WorksheetExtensions.Import method overload that has the IDataValueConverter interface as a parameter. It enables you to change data before insertion in a worksheet.
To accomplish data conversion, create a class that implements the IDataValueConverter interface and pass it as the parameter to the WorksheetExtensions.Import method.