Opens a standard dialog box that is used to set up object or sheet objects properties.
Command parameters are passed in the Data property. To ensure command execution, determine one of the following values in this property:
Value type | Description |
ITabObject | The sheet object, for which the parameter setup dialog box is to be displayed. |
Array | The array of the Variant type. Each array element is a sheet object described by the ITabObject interface. If the type of array element is not ITabObject, the element is ignored. |
The command is used only for regular reports. Executing the command shows logical True if the OK button is clicked in the dialog box, and False if the Cancel button is clicked.
Executing the example requires a form, the Button1 button on this form, the ReportBox component and the UiReport component named UiReport1, which is used as the data source for the ReportBox component. The active sheet of the regular report linked to the UiReport1 component contains at least one object.
Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
Report: IPrxReport;
Sheet: ITabSheet;
Target: IUiCommandTarget;
Context: IUiCommandExecutionContext;
Begin
Report := UiReport1.Instance As IPrxReport;
Sheet := (Report.ActiveSheet As IPrxTable).TabSheet;
Target := WinApplication.Instance.GetPluginTarget("Report");
Context := Target.CreateExecutionContext;
Context.Data := Sheet.Objects.Item(0);
Target.Execute("ObjectProperties", Context);
End Sub Button1OnClick;
Clicking the button opens a dialog box for setting up parameters of the first object located on the active report sheet.
The requirements and result of the Fore.NET example execution match with those in the Fore example. Use Fore.NET analogs instead of Fore components.
Imports Prognoz.Platform.Interop.Report;
Imports Prognoz.Platform.Interop.Tab;
Imports Prognoz.Platform.Interop.Ui;
Private Sub button1_Click(sender: System.Object; e: System.EventArgs);
Var
Report: IPrxReport;
Sheet: ITabSheet;
WinApp: WinApplication = New WinApplicationClass_2();
Target: IUiCommandTarget;
Context: IUiCommandExecutionContext;
Begin
Report := UiReportNet1.ReportUi.Report;
Sheet := (Report.ActiveSheet As IPrxTable).TabSheet;
Target := WinApp.GetPluginTarget("Report");
Context := Target.CreateExecutionContext();
Context.Data := Sheet.Objects.Item[0];
Target.Execute("ObjectProperties", Context, Null);
End Sub;
See also: