Select to view content in your preferred language

Using a Geocoder outside of the Viewer

733
1
Jump to solution
07-02-2013 09:31 AM
DavidBoiano
Deactivated User
Hi all,

I am trying to recreate an application that I currently have working in the Flex Viewer.  It uses a single line geocode service that is hosted on ArcGIS Server 10.0.  In the Viewer I am using the header control widget to configure my geocode service with the following tags: 
<geocoder>   <url>http://ntts10/ArcGIS/rest/services/Locators/BWSC_FULLNEIGHBORHOOD/GeocodeServer</url>   <zoomscale>1000</zoomscale>   <autocomplete>true</autocomplete>   <maxlocations>8</maxlocations>  </geocoder>


Now, when I try to insert a geocoder into a Border Container on a straight Flex API application, using the same properties, I can't get it to work.  The search box appears, but when I type an address into it, it neither shows autocomplete results nor does it seem to find any results at all.  Here is my code where I instered it in my mxml application: 
 <esri:Geocoder autoComplete="true"         maxLocations="8"         url="http://ntts10/ArcGIS/rest/services/Locators/BWSC_FULLNEIGHBORHOOD/GeocodeServer"/> 


Lastly, when trying to mirror the properties I had set on the geocoder in the Viewer, I did not find a property to set <zoomscale> to 1000 like I had set in the HeaderController xml file.  Is there a way to configure this outside the viewer?

Thanks!

David
Tags (2)
0 Kudos
1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Emeritus
David,

   The Geocoders autocomplete property is false by default. Also you can grab the src/com/esri/viewer/components/GeocoderComponent.mxml from the Viewer an remove all the viewer portions of the code and have a great starting point for you API app.

View solution in original post

0 Kudos
1 Reply
RobertScheitlin__GISP
MVP Emeritus
David,

   The Geocoders autocomplete property is false by default. Also you can grab the src/com/esri/viewer/components/GeocoderComponent.mxml from the Viewer an remove all the viewer portions of the code and have a great starting point for you API app.
0 Kudos