HOW TO

Add on-screen widgets in Web AppBuilder for ArcGIS (Developer Edition)

Last Published: April 25, 2020

Summary

When using Web AppBuilder for ArcGIS (Developer Edition), users may want to add more on-screen widgets to the map. By default, only four widgets are allowed to be added to the map at a time. However, more widgets can be added by modifying the config.json file of the desired app.

Procedure

The instructions provided describe how to allow additional on-screen widgets to be added in Web AppBuilder for ArcGIS (Developer Edition).

  1. Open the Web AppBuilder for ArcGIS folder and open the server folder.
     
    The picture of server folder.
     
  2. Open the desired app folder, and edit the config.json file using a text editor (for example, Notepad++.)
  3. Search the file for the widgetOnScreen segment.
  4. Find an empty positioning element or the last section of the segment, and add the following code.
     
    {
            "position": {
              "left": 205,
              "top": 45,
              "relativeTo": "map"
            },
            "placeholderIndex": 1,
            "id": "_8"
          }

    The following is an example of the final code snippet.

    Picture of final code snippet
     
    In the example above, the slot below CustomWidgetTemplate is used.
    Note:
    When creating an empty widget section, it is recommended to add the value of 50 to the left parameter to correctly align the widget.

Article ID: 000015753

Software:
  • ArcGIS Web AppBuilder

Receive notifications and find solutions for new or common issues

Get summarized answers and video solutions from our new AI chatbot.

Download the Esri Support App

Related Information

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options