Opens a standard dialog box that is used to set up parameters of the map located on one of the sheets of regular report.
Command parameters are passed in the Data property. Executing the command requires to specify an array of the Variant type in this property, the elements of this array contain the following values:
Value type | Description |
Element 1: IPrxMap | The map, for which the parameter setup dialog box is to be displayed. |
Element 2: IPrxReport | The regular report, on a page of which a map is created. |
Element 3: PrxAdapterDataType | The type of data placement for adapter. Optional element. If the element is not defined, dimensions and factors can be bound to the data in the sheets or to data slices. |
The command is used only for regular reports. Executing the command shows 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 with the Button1 button, the ReportBox component and the UiReport component named UiReport1, which is used as a data source for the ReportBox component. The active sheet of the regular report connected to the UiReport1 component contains a map with the PrxMap1 identifier.
Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
Rep: IPrxReport;
Map: IPrxMap;
Target: IUiCommandTarget;
Context: IUiCommandExecutionContext;
Data: Array;
Begin
Rep := UiReport1.Instance As IPrxReport;
Map := (Rep.ActiveSheet As IPrxTable).TabSheet.Objects.Object("PrxMap1") As IPrxMap;
Target := WinApplication.Instance.GetPluginTarget("Report");
Context := Target.CreateExecutionContext;
Data := New Variant[2];
Data[0] := Map;
Data[1] := Rep;
Context.Data := Data;
Target.Execute("MapSetup", Context);
End Sub Button1OnClick;
Clicking the button opens a standard dialog box that is used to set up map parameters. Layers and factors can be bound to the data in the sheets or to data slices.
See also: