getSilverlightInstance();
The getSilverlightInstance method returns an instance of a Silverlight object.
Executing the example requires that the HTML page contains the ExpressBox component named expressBox (see Example of Creating the ExpressBox Component) and have a loaded map in the working area. Load a Silverlight3D map to the express report:
// Get view of express report map var mapView = expressBox.getDataView().getMapView(); // Set new map type: Silverlight mapView.setMapType(PP.MapChart.Type.Silverlight3D); // Place drop-down menus over the map mapView.onDropDownStateChanged(True);
After the new map is loaded, get an instance of the Silverlight object and define its identifier:
if (mapView.isSLAvailable()) { // Get Silverlight object instance console.log(mapView.getSilverlightInstance().id); };
After executing the example the browser console displays identifier of the Silverlight object:
Silverlight object identifier: 601f55b0-f316-4bb7-a4fd-529e4c2cdea1
The Silverlight3D map will look as follows:
As the onDropDownStateChanged method was called with the parameter set to True, on showing the drop-down list (the context list in this case), the Silverlight map is replaced with an image of the SVG map:
See also: