<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Address locator problem in ArcGIS API for Silverlight Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557475#M14325</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;With the 'address to location' sample, you can use 'centerAndZoom' instead of ZoomToResolution this way:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;//if (_firstZoom)
//{
//&amp;nbsp;&amp;nbsp;&amp;nbsp; MyMap.ZoomToResolution(MyMap.Resolution / 6, pt);
//&amp;nbsp;&amp;nbsp;&amp;nbsp; _firstZoom = false;
//}
//else
//&amp;nbsp;&amp;nbsp;&amp;nbsp; MyMap.PanTo(pt);
centerAndZoom(MyMap, pt, MyMap.MinimumResolution * 4);
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This will give good results.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;/Dominique&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 12 Dec 2021 00:04:03 GMT</pubDate>
    <dc:creator>DominiqueBroux</dc:creator>
    <dc:date>2021-12-12T00:04:03Z</dc:date>
    <item>
      <title>Address locator problem</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557469#M14319</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The ESRI sample at &lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://resources.esri.com/help/9.3/arcgisserver/apis/silverlight/samples/start.htm#AddressToLocation"&gt;http://resources.esri.com/help/9.3/arcgisserver/apis/silverlight/samples/start.htm#AddressToLocation&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;requires 2 clicks to get the map to zoom AND center on the found address. I have experimented several ways to get it to do both on a single click but haven't been able to find a solution. Is this a bug in the zoom function? Has anyone found a workaround?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 26 Apr 2010 19:53:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557469#M14319</guid>
      <dc:creator>DonFreeman</dc:creator>
      <dc:date>2010-04-26T19:53:26Z</dc:date>
    </item>
    <item>
      <title>Address locator problem</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557470#M14320</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I'm not seeing this. Could you tell us a little about what OS, SL version and browser you are using?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 26 Apr 2010 20:23:23 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557470#M14320</guid>
      <dc:creator>dotMorten_esri</dc:creator>
      <dc:date>2010-04-26T20:23:23Z</dc:date>
    </item>
    <item>
      <title>Address locator problem</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557471#M14321</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Looks like there is a small issue in the sample because the first time the user selects an address, it's calling ZoomToResolution but this method is not supposed to center on the given point.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;If we try calling successively ZoomToResolution + PanTo, we run into trouble because these methods are asynchronous.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;There is already a thread about this issue (without definitive solution) &lt;/SPAN&gt;&lt;A href="http://forums.arcgis.com/threads/2269-Zoom-and-Pan-with-Address-locator"&gt;http://forums.arcgis.com/threads/2269-Zoom-and-Pan-with-Address-locator&lt;/A&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Dominique&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 Apr 2010 10:11:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557471#M14321</guid>
      <dc:creator>DominiqueBroux</dc:creator>
      <dc:date>2010-04-27T10:11:45Z</dc:date>
    </item>
    <item>
      <title>Address locator problem</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557472#M14322</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;After removing the dust from my student geometry books, I eventually got a method which centers AND pans to a point.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;private void centerAndZoom(ESRI.ArcGIS.Client.Map map, ESRI.ArcGIS.Client.Geometry.MapPoint mapPoint, double resolution)
{
 double ratio = 1.0;
 if (map.Resolution != 0.0)
&amp;nbsp; ratio = resolution / map.Resolution;

 if (ratio == 1.0)
&amp;nbsp; map.PanTo(mapPoint);
 else
 {
&amp;nbsp; ESRI.ArcGIS.Client.Geometry.MapPoint mapCenter = map.Extent.GetCenter();
&amp;nbsp; double X = (mapPoint.X - ratio * mapCenter.X) / (1 - ratio);
&amp;nbsp; double Y = (mapPoint.Y - ratio * mapCenter.Y) / (1 - ratio);
&amp;nbsp; map.ZoomToResolution(resolution, new ESRI.ArcGIS.Client.Geometry.MapPoint(X, Y));
 }
}&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;/Dominique&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 00:04:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557472#M14322</guid>
      <dc:creator>DominiqueBroux</dc:creator>
      <dc:date>2021-12-12T00:04:00Z</dc:date>
    </item>
    <item>
      <title>Address locator problem</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557473#M14323</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks dbroux -&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Can you tell me how to assign a value to the variable resolution?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 Apr 2010 15:15:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557473#M14323</guid>
      <dc:creator>DonFreeman</dc:creator>
      <dc:date>2010-04-27T15:15:47Z</dc:date>
    </item>
    <item>
      <title>Address locator problem</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557474#M14324</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;After more thought I deduced that any arbitrary number that produces a good result would probably be OK, so I settled on a value of 150.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks again.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 Apr 2010 16:40:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557474#M14324</guid>
      <dc:creator>DonFreeman</dc:creator>
      <dc:date>2010-04-27T16:40:03Z</dc:date>
    </item>
    <item>
      <title>Address locator problem</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557475#M14325</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;With the 'address to location' sample, you can use 'centerAndZoom' instead of ZoomToResolution this way:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;//if (_firstZoom)
//{
//&amp;nbsp;&amp;nbsp;&amp;nbsp; MyMap.ZoomToResolution(MyMap.Resolution / 6, pt);
//&amp;nbsp;&amp;nbsp;&amp;nbsp; _firstZoom = false;
//}
//else
//&amp;nbsp;&amp;nbsp;&amp;nbsp; MyMap.PanTo(pt);
centerAndZoom(MyMap, pt, MyMap.MinimumResolution * 4);
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This will give good results.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;/Dominique&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 00:04:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557475#M14325</guid>
      <dc:creator>DominiqueBroux</dc:creator>
      <dc:date>2021-12-12T00:04:03Z</dc:date>
    </item>
    <item>
      <title>Re: Address locator problem</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557476#M14326</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am attempting to get an App up and running using an Address locator. I want to pass the address through a url (&lt;/SPAN&gt;&lt;A href="http://gisadev/cismap?Address=301"&gt;http://gisadev/cismap?Address=301&lt;/A&gt;&lt;SPAN&gt; E Central). My app grabs the correct parameters and is supposed to zoom to the appropriate address after finding a match.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This works great in Visual Studio when testing and when running directly on the server. But when I attempt to run the application from my client machine and copy/paste the exact same url to IE I can find the correct address but the zoom to function isn't working. I know that I am finding a match because the canidates list is populated. The map will only load at the full extent instead of zooming to the correct address.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any thoughts on what could be different between VS, the server that the app is published to, and any clients. The map loads fine without errors on all three (VS, server, and client) but only the client machine won't zoom to the address. In VS the URL, if entered in as &lt;/SPAN&gt;&lt;A href="http://gisadev/cismap?Address=301"&gt;http://gisadev/cismap?Address=301&lt;/A&gt;&lt;SPAN&gt; E Central, will automatically add a %20 for the spaces. On the server the spaces stay spaces when running the app. Both find the correct address and complete the zoomto. When I run the app on the client machine by typing in the URL with spaces it fills in %20 again, finds the address and doesn't zoom to. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Sorry for the long post. It is hard to explain even when someone is sitting here looking at the problem as I explain.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Sep 2010 13:49:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/address-locator-problem/m-p/557476#M14326</guid>
      <dc:creator>BrandonIves</dc:creator>
      <dc:date>2010-09-12T13:49:38Z</dc:date>
    </item>
  </channel>
</rss>

