ITabSheet.PasteEx

Syntax

PasteEx(

PasteMode: TabPasteMode;

[SkipEmptyCells: Boolean = False];

[Transpose: Boolean = False]);

Parameters

PasteMode. Insert mode.

SkipEmptyCells. Indicates whether empty cells are skipped.

Transpose. Indicates whether data should be transposed on insert.

Description

The PasteEx method performs special pasting.

Comments

To paste data from the clipboard to the marked table area, use the ITabSheet.Paste method.

Special paste from the clipboard is not supported if data is copied in a third-party source.

If the inserted range contains empty cells, and the SkipEmptyCells parameter is set to True, formulas, formatting and comments are not inserted for these cells.

It is used only in the desktop application.

Example

Executing the example requires a regular report with the Regl_rep identifier.

Add links to the Metabase, Report and Tab system assemblies.

Sub UserProc;
Var
    MB: IMetabase;
    MObj: IMetabaseObject;
    Rep: IPrxReport;
    Tab: ITabSheet;
    Sheet: IPrxTable;
Begin
    MB := MetabaseClass.Active;
    MObj := MB.ItemById("Regl_rep").Edit;
    Rep := MObj As IPrxReport;
    Sheet := Rep.Sheets.Item(0As IPrxTable;
    Tab := Sheet.TabSheet;
    Tab.View.Selection.Range := Tab.Cells(0071);
    Tab.View.Selection.Copy;
    Tab.View.Selection.Range := Tab.Cell(55);
    Tab.PasteEx(TabPasteMode.Values, TrueTrue);
    MObj.Save;
End Sub UserProc;

After executing the example the regular report contains values of the A0:B7 cells that are copied and pasted into the row, starting from the E4 cell.

See also:

ITabSheet