AddDescriptor(Desc: IMetabaseObjectDescriptor): IEaxDataSource;
Desc. Description of the repository object that will be used as an express report data source.
The AddDescriptor method adds a data source to express report by object description in the repository.
Unlike the IEaxDataSources.Add method, the AddDescriptor method adds a data source without its prior opening.
Executing the example requires an express report with the EXPRESS_REPORT identifier and a cube with the CUBE identifier.
Add links to the Express, Metabase system assemblies.
Sub UserProc;
Var
MB: IMetabase;
Expr: IEaxAnalyzer;
ExprDS: IEaxDataSources;
Cube: IMetabaseObjectDescriptor;
Begin
MB := MetabaseClass.Active;
Expr := MB.ItemById("EXPRESS_REPORT").Edit As IEaxAnalyzer;
ExprDS := Expr.DataSources;
Cube := MB.ItemById("CUBE");
ExprDs.AddDescriptor(Cube);
(Expr As IMetabaseObject).Save;
End Sub UserProc;
After executing the example the specified cube will be added as a data source for the express report.
See also: