Extending the ArcGIS Map Web Part
Esri Maps for SharePoint allows you to develop custom functionality for the ArcGIS Map Web Part by creating add-ins. Add-ins are Silverlight assemblies that contain one or more commands or map behaviors that interact with the Map Web Part. To help you write extensions, the Map Web Part provides a lightweight, flexible, and extensible application programming interface (API) included in the ArcGIS Extensibility SDK for Silverlight. The API provides access to the map and selected layer and allows you to show dialog boxes within the Map Web Part that can contain any Silverlight FrameworkElement.
The ArcGIS Extensibility SDK for Silverlight 3.1 is built on the ArcGIS API for Silverlight 3.1
Once you have written an add-in, the process for adding it to the Map Web Part is straightforward. Add the compiled Silverlight application (.xap) file to the Esri Maps Extensions library. Then when designers edit a Map Web Part within the same site collection, they can add the tools and behaviors contained in your extension through an easy-to-use UI. Tools that are added are exposed as buttons on the ribbon with a label and icon specified by the designer. Clicking a button invokes its associated command. Behaviors that are added are enabled when the Map Web Part loads and can be managed through a dialog box.
To add an add-in to the Map Web Part, complete the following steps:
- Create your add-in, referencing the Writing tools and Writing map behaviors topics as necessary.
- Browse to the Site Settings page by opening the Site Actions menu and clicking Site Settings.
- Under the Esri Maps for SharePoint Administration heading, click Extensions.
- Click Add Document. The Upload Document dialog box appears.
- Click the Browse button to open the Choose File to Upload dialog box.
- Locate and select the .xap file containing the add-in and click Open.The .xap file will be uploaded to the library. Once this is done, the tools and behaviors within the add-in package will be available when adding tools to ArcGIS Map Web Parts within the same site collection.