IPrxControls.FindById

Syntax

FindById(Id: String): IPrxControl;

Parameters

Id - identifier of a control.

Description

The FindById method searches for and returns an object containing a control. Identifier of a control is passed using the Id parameter.

Example

Sub Main;

Var

MB: IMetabase;

Report: IPrxReport;

Contrls: IPrxControls;

Contrl: IPrxControl;

i: Integer;

Begin

MB := MetabaseClass.Active;

Report := MB.ItemById("Report").Bind As IPrxReport;

Contrls := Report.Sheets.Item(0).Controls;

Contrl := Contrls.FindById("Item5");

i := Contrl.Key;

End Sub Main;

After executing the example the "i" variable contains key of the control with the Item5 identifier. The identifier of the regular report - Report.

See also:

IPrxControls