<?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 Re: Displaying an info window for a selected graphic without click event to get ancho in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/displaying-an-info-window-for-a-selected-graphic/m-p/461614#M42667</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Just found your post while trying to do something similar. I already had a point so I just had to convert it to screen coordinates. In your case you might use the center of your polygon. So something like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;

var screenpoint = map.toScreen(polygon.getExtent().getCenter()));

map.infoWindow.show(screenpoint, map.getInfoWindowAnchor(screenpoint));

&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 11 Dec 2021 20:31:21 GMT</pubDate>
    <dc:creator>ShaneCastlen</dc:creator>
    <dc:date>2021-12-11T20:31:21Z</dc:date>
    <item>
      <title>Displaying an info window for a selected graphic without click event to get anchor pt</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/displaying-an-info-window-for-a-selected-graphic/m-p/461613#M42666</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This is probably staring me in the face but can't seem to determine from the API how you would go about doing this.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have a datagrid that list my feature class attributes, enables me to select the record of interest &amp;amp; highlight on the map.&amp;nbsp; From here, i want an infowindow to automatically open (nil user interaction with the map); While i can get this to work for a point feature class (via the infoWindow.show()), i cannot get it to work for a polygon as infoWindow.show() is expecting a point for its anchor. Appreciate any tips on how to implement this type of behaviour.. Using JS API 1.6.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Brad&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 16 Aug 2010 14:05:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/displaying-an-info-window-for-a-selected-graphic/m-p/461613#M42666</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2010-08-16T14:05:37Z</dc:date>
    </item>
    <item>
      <title>Re: Displaying an info window for a selected graphic without click event to get ancho</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/displaying-an-info-window-for-a-selected-graphic/m-p/461614#M42667</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Just found your post while trying to do something similar. I already had a point so I just had to convert it to screen coordinates. In your case you might use the center of your polygon. So something like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;

var screenpoint = map.toScreen(polygon.getExtent().getCenter()));

map.infoWindow.show(screenpoint, map.getInfoWindowAnchor(screenpoint));

&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 20:31:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/displaying-an-info-window-for-a-selected-graphic/m-p/461614#M42667</guid>
      <dc:creator>ShaneCastlen</dc:creator>
      <dc:date>2021-12-11T20:31:21Z</dc:date>
    </item>
  </channel>
</rss>

