Skip to main content

TdxSpreadSheetTableView.FillData(TRect,TcxDirection,Integer) Method

Populates cells from the specified source.

Declaration

procedure FillData(const ASourceArea: TRect; ADirection: TcxDirection; ACount: Integer); overload; virtual;

Parameters

Name Type
ASourceArea TRect
ADirection TcxDirection
ACount Integer

Remarks

You can call any of these overloaded procedure variants to programmatically employ the AutoFill functionality. Different FillData procedure variants provide different ways to specify source and target cell ranges:

Variant

Source

Destination

1

The cell value source is a contiguous cell selection. If the current selection is empty or includes more than one cell range, a FillData procedure call raises an EdxSpreadSheetError exception.

The procedure variant accepts the destination cell range’s direction from the source range as the ADirection parameter and the destination range’s length (in cells) as the ACount parameter.

A FillData procedure call has no effect if there is no valid destination cell range (that is, the procedure accepts dirNone as the ADirection parameter or a non-positive value as the ACount parameter).

2

The procedure variant accepts a reference (as a string in the A1 format) to the destination cell range.

The procedure variant accepts a reference to the destination cell range as the ATargetArea parameter in the same manner as the reference to the source range.

A FillData procedure call clears the source cell range if it is either a part of the destination cell range, or the ranges are not adjacent.

3

The procedure variant accepts a TRect value as the ASourceArea parameter. The value indicates the source cell range.

The procedure variant accepts the destination cell range as the ATargetArea parameter in the same manner as the source range. The destination range’s behavior is the same as in the second procedure variant’s case.

4

The procedure variant accepts a reference (as a string in A1 format) to the destination cell range.

These procedure variants accept the destination cell range’s direction as the ADirection parameter and its length (in cells) as the ACount parameter like the first overloaded procedure variant does.

5

The procedure variant accepts a TRect value that indicates the source cell range.

Note

A FillData procedure call has no effect if the CanFillData function returns False.

See Also