Select to view content in your preferred language

Adding add-ins to popup toolbar in DefaultTools.xml

918
1
09-03-2013 07:24 AM
MattMcGuire
Regular Contributor
I would like to add an Add-in to the Popup Toolbar. The add-in has already been added to SharePoint  (http://resources.arcgis.com/en/help/sharepoint/concepts/index.html#/Configuring_add_ins/015900000083...)

What is the proper format (required paths, namespace and class references) to an add-in to the Popup Toolbar of DefaultTools.xml?

Is there an example which shows adding the Measure Tool or Get Related Records to the DefaultTools.xml?
0 Kudos
1 Reply
KatherineDalton
Esri Regular Contributor
Hi Matt,

As you've noticed, adding a tool to the pop-up toolbar requires editing the Default.xml file in Esri Maps for SharePoint. Here is how you would add the Query Related Records tool (which only functions on the pop-up toolbar). I put the key lines in bold. Note that the QueryRelatedRecords add-in should already be listed in your Esri Maps Extensions list, but the icon may be missing. I've attached the icon here. Upload it to the Extensions list and it should work.

We'll work to update the documentation so there is an example of editing the Default.xml file. Thanks.

Katy


<ToolPanels xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:esri="http://schemas.esri.com/arcgis/mapping/2009"
xmlns:QueryRelatedRecords="clr-namespace:QueryRelatedRecords.AddIns;assembly=QueryRelatedRecords.AddIns">
  <ToolPanel Name="Attribute Table Toolbar" ContainerName="FeatureDataGridToolbarContainer" Orientation="Horizontal">
�?�

  </ToolPanel>
  <ToolPanel Name="Popup Toolbar" ContainerName="PopupToolbarContainer" Orientation="Horizontal">
    <Tools>
      <Tool Icon="/_layouts/15/ESRI.ArcGIS.Mapping.SharePoint/Images/toolbar/DeleteGraphicCommand16.png">
        <Tool.Class>
          <esri:DeleteGraphicCommand />
        </Tool.Class>
      </Tool>
      <Tool Icon="/_layouts/15/ESRI.ArcGIS.Mapping.SharePoint/Images/toolbar/EditShapeCommand16.png">
        <Tool.Class>
          <esri:EditShapeCommand />
        </Tool.Class>
      </Tool>
      <Tool Icon="/_layouts/15/ESRI.ArcGIS.Mapping.SharePoint/Images/toolbar/EditValuesCommand16.png">
        <Tool.Class>
          <esri:EditValuesCommand />
        </Tool.Class>
      </Tool>
      <Tool Icon="/_layouts/15/ESRI.ArcGIS.Mapping.SharePoint/Images/toolbar/AddAttachmentsCommand16.png">
        <Tool.Class>
          <esri:AddAttachmentsCommand />
        </Tool.Class>
      </Tool>
<Tool  Label="Query Related Records" Icon="/_layouts/15/ESRI.ArcGIS.Mapping.SharePoint/images/GeodatabaseRelationshipSelect16.png" Description="Query the related records of the feature">
        <Tool.Class>
          <QueryRelatedRecords:QueryRelatedTool />
        </Tool.Class>
      </Tool>

    </Tools>
  </ToolPanel>
</ToolPanels>
Katy Dalton | Technical Consultant
THE SCIENCE OF WHERE™