Export: IMetabaseObject;
The Export method exports a model displayed in the component to a regular report.
The method work results in the object that contains a regular report. This regular report is opened for edit.
Executing the example requires a form, a button with the Button1 identifier on this form, the ModelBox component with the ModelBox1 identifier. Source data for the ModelBox component is the UiModel component.
Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
Obj: IMetabaseObject;
Rep: IPrxReport;
Begin
Obj := ModelBox1.Export;
Rep := Obj As IPrxReport;
If (Rep <> Null) Then
Rep.SaveToFile("c:\my.ppreport", PrxReportSaveMode.Full);
End If;
End Sub Button1OnClick;
After executing the example the model, displayed in the ModelBox1 component, is transformed into the regular report and exported in the my.ppreport report file.
See also: