Locate widget tags

This page describes an older version, please read about the latest version at:
http://resources.arcgis.com/en/help/flex-viewer/concepts/

Configuration file for Locate Widget

The general structure of the the Locate Widget configuration file is shown by the conceptual graphic below.

Conceptual overview of configuration options for Locate widget

The file is defined by a <configuration> tag that identifies the file as a configuration file for the Viewer application. It has the following child tags:

<locator>
URL address of the geocoding service or "bing" to use the Bing Maps locator service. If using "bing", you must use your own Bing key to the main configuration file using the <bing key="..."/> syntax.
LicenseLicense:

There are restrictions when using Bing Maps geocoding:

  • Geocodes may not be displayed on any map other than a Bing Map.
  • Geocodes may not be stored for any purpose except caching for performance.
  • For more information on the Bing Maps terms of use when using Esri products, see http://www.esri.com/legal/pdfs/e-802-bing-mapsvcs.pdf.

<initialview>
Which view the widget should open with. The two options are address (for the default address view) and coordinates (for the coordinates view).
<minscore>
The minimum acceptable match score for an address or longitude/latitude coordinate value with the geocoding service. Values range from 0 to 100. The default is 40.
<fields>
Which fields to display and how to display them. Only applicable when not using single line input. It has the following child tag:
<field>
How to customize the input fields for a locator, for example http://tasks.arcgisonline.com/ArcGIS/rest/services/Locators/TA_Address_EU/GeocodeServer has four fields. You can use this to provide defaults for certain fields, and/or hard-code certain fields (so they can only locate addresses within specific city or list of zip codes). It has the following attributes:
  • name - The name of one of the input fields. Required.
  • alias - An alias to display instead of the "name".
  • defaultvalue - A default value for this field. If not set, text fields will be empty, while lists will default to the first item.
  • editable - Boolean. Determines whether this field is editable by end-users. Set to faulse if you want to hard-code one of the strings, for example a country or city. Default is "true".
  • visible - Boolean. Determines whether to display this field or not to end-users. You might want to hide a field after setting a default value using the defaultvalue attribute. Default is "true".
  • listvalues - Set list of values for end-users to pick from for this field. Instead of showing a text input box, present a dropdown list. Can be used for the countries for a European locator, or a selected set of ZIP Codes.
<zoomscale>
Scale to zoom to when item is clicked in the widget results. Default is 10000 (i.e. 1:10,000).
<excludefield>
Returned fields to exclude from the display.
<useproxy>
If true, will use the proxy specified in the main configuration file.
<usesingleline>
If the locator supports single line geocoding, the widget will default to single line input. Set this to false to not use the single line geocoder.
LegacyLegacy:
<listfield>
Deprecated as of version 2.3. Use <fields> instead. Supporting attribute field that helps perform the geocoding operation for the specified geocoding service.
<listvalues>
Deprecated as of version 2.3. Use <fields listvalues="..."> instead. List of known values in the attribute field assigned to the <listfield> tag.

Labels

In addition, the configuration file also supports changing the labels used in the widget dialog (this is not shown in the conceptual graphic).

<labels>
Container for labels that can be modified in this widget. It has several child tags:
<addresslabel>
Tooltip label for the first titlebar button (default for English is "Address").
<addresstitle>
Widget dialog subtitle when search by address is selected (default for English is "Enter the address").
<coordinateslabel>
Tooltip label for the second titlebar button (default for English is "Coordinates").
<coordinatestitle>
Widget dialog subtitle when search by coordinates is selected (default for English is "Enter the coordinates").
<resultslabel>
Tooltip for the third titlebar button (default for English is "Results").
<noresultlabel>
Label to show when no features was found (default for English is "No matching locations found").
<submitlabel>
Label for the submit button (default for English is "Locate").
<clearlabel>
Label for the clear widget inputs (default for English is "Clear").
<xlabel>
Label for the x-coordinate input box (default for English is "Longitude(X)").
<ylabel>
Label for the y-coordinate input box (default for English is "Latitude (Y)").
<xexamplevalue>
Example x coordinate values displayed in the locate widget (default for English is -77.03655).
<yexamplevalue>
Example y coordinate values displayed in the locate widget (default for English is 38.89767).
<loadinglabel>
Label for status window as the locate widget is retrieving results (default for English is "Loading...").
<locationslabel>
Widget dialog subtitle when results are displayed (default for English is "Locations found:").

The xexamplevalue and yexamplevalue default values change based on which locale is specified in the main configuration file.

Symbols

<symbols>
Property for custom symbols in the widget. Specifically, the symbol that is shown for each returned result. It has one child tag:
<picturemarkersymbol>
Defines a picture marker symbol. It has the following attributes:
  • url - URL or path to the picture marker symbol location (default is widget icon).
  • height - Symbol height (in pixels - default is 30)
  • width - Symbol width (in pixels - default is 30).
  • xoffset - Symbol offset along the x-axis (in pixels - default is 0).
  • yoffset- Symbol offset along the y-axis (in pixels - default is 0).

Test drive the Locate widget.

2/15/2012