Show contents 

Report > Report Assembly Interfaces > IPrxTableDataBinding > IPrxTableDataBinding.AttachCell

IPrxTableDataBinding.AttachCell

Syntax

AttachCell(Row: Integer; Column: Integer; Slice: IPrxSlice; Selection: IDimSelectionSet): Boolean;

Parameters

Row - row.

Column.

Slice - data source slice.

Selection - slice selection.

Description

The AttachCell method binds a cell to a data slice. The method returns True when completed successfully or False when failed.

When the sheet is calculated, the binding is reset.

Example

The following example assumes that there is the Report object with the IPrxReport type.

Sub UserProc;
Var
    MB: IMetabase;
    Report: IPrxReport;
    SheetT: IPrxTable;
    Slice: IPrxSlice;
    DataS: IPrxDataSource;
    Sel: IDimSelectionSet;
    Result: boolean;
Begin
    MB := MetabaseClass.Active;
    Report := MB.ItemById("REPORT").Bind As IPrxReport;
    Report.Recalc;
    DataS := Report.DataSources.Item(0);
    Slice := DataS.Slices.Item(0);
    Sel := Slice.Selection;
    SheetT := Report.Sheets.Item(0As IPrxTable;
    Result := SheetT.DataBinding.AttachCell(00, Slice, Sel);
    If Result Then
        WinApplication.InformationBox("Bounded");
    Else
        WinApplication.InformationBox("Bind is not executed");
    End If;
End Sub UserProc;

After executing the example the system displays an appropriate message depending on the result.

See also:

IPrxTableDataBinding