Select to view content in your preferred language

ArcGIS Viewer for Flex 3.4 Header Controller Locatoroptions

1275
6
07-09-2013 07:08 AM
EamonnDoyle
Esri Contributor
Hi

I am trying to modify the HeaderControllerWidget.xml to search http://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer only for locations in Ireland by using the

<locatoroptions>
<sourcecountry>IRL</sourcecountry>
</locatoroptions>

However a search on say Dublin in http://showcase.esri-ireland.ie/builtflexviewers/GeoCode/ still considers and returns candidates outside Ireland. Can anyone advice on what I may be doing wrong?

Thanks

Eamonn
Tags (2)
0 Kudos
6 Replies
RobertScheitlin__GISP
MVP Emeritus
Eamonn,

   Your xml should look like this for the geocoder portion:

<configuration>
    <geocoder>
        <url>http://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer</url>
        <locatoroptions>
            <sourcecountry>IRL</sourcecountry>
        </locatoroptions>
    </geocoder>
0 Kudos
EamonnDoyle
Esri Contributor
Robert

Thanks for your suggestion. Looks like I had some incorrect XML. However even when corrected I don't get the expected results as the screenshot shows.

Eamonn
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Eamonn,

   Not sure what is going wrong for you... Here is screenshot of mine with that exact XML change to the header widget

[ATTACH=CONFIG]25831[/ATTACH]
0 Kudos
EamonnDoyle
Esri Contributor
Thanks Robert

I had upgraded a 3.3 Viewer, when I start with a 3.4 Viewer things work as expected.

Eamonn
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Eamonn,

  Strange as I did all my testing in a 3.3 viewer and got it to work fine.

Don't forget to click the Mark as answer check on this post and to click the top arrow (promote).
Follow these steps as shown in the below graphic:

0 Kudos
MichaelVolz
Esteemed Contributor
Eamonn:

When you say "you upgraded a 3.3 viewer", do you mean that you had widgets working with the FlexViewer 3.3 compiled version and you just copied your config files from the 3.3 viewer to a newer FlexViewer 3.4 compiled version?

I ask because I have found that performing this type of upgrade often times does not work.  I need to resort to manually modifying the new 3.4 widgets to match the older version widgets.  This in itself is sometimes tricky as there could be changes to the config files that you also need to account for where the widget was enhanced or the config was changed to make the widget more user friendly.
0 Kudos