<?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: Bind Identify Results to a datagroup in ArcGIS API for Flex Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/bind-identify-results-to-a-datagroup/m-p/602570#M13418</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;thanks for the information, I am still playing with the code. Have not been able to figure this out yet. Not sure if the datagroup is the best way to go. The results are being viewed in a mobile android app, that is why i am not using a datagrid&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 28 Jun 2011 13:56:36 GMT</pubDate>
    <dc:creator>AaronNash</dc:creator>
    <dc:date>2011-06-28T13:56:36Z</dc:date>
    <item>
      <title>Bind Identify Results to a datagroup</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/bind-identify-results-to-a-datagroup/m-p/602568#M13416</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am looking at the identify code sample and I have it running in an application. I would like the results to show in a datagroup like how Robert's Identify Widget works. This is the code that I am using out of the sample code section. The pop up works fine on a mouse click and the data is populated.&amp;nbsp; &lt;/SPAN&gt;&lt;PRE class="plain" name="code"&gt;&amp;nbsp; private function mapClickHandler(event:MapMouseEvent):void
&amp;nbsp; {
&amp;nbsp;&amp;nbsp; clickGraphicsLayer.clear();&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp; var identifyParams:IdentifyParameters = new IdentifyParameters();
&amp;nbsp;&amp;nbsp; identifyParams.returnGeometry = true;
&amp;nbsp;&amp;nbsp; identifyParams.tolerance = 3;
&amp;nbsp;&amp;nbsp; identifyParams.width = map.width;
&amp;nbsp;&amp;nbsp; identifyParams.height = map.height;
&amp;nbsp;&amp;nbsp; identifyParams.geometry = event.mapPoint;
&amp;nbsp;&amp;nbsp; identifyParams.mapExtent = map.extent;
&amp;nbsp;&amp;nbsp; identifyParams.spatialReference = map.spatialReference;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp; var clickGraphic:Graphic = new Graphic(event.mapPoint, clickPtSym);
&amp;nbsp;&amp;nbsp; clickGraphicsLayer.add(clickGraphic);&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp; identifyTask.execute(identifyParams, new AsyncResponder(myResultFunction, myFaultFunction, clickGraphic));
&amp;nbsp; }

&amp;nbsp; private function myResultFunction(results:Array, clickGraphic:Graphic = null):void
&amp;nbsp; {
&amp;nbsp;&amp;nbsp; if (results &amp;amp;&amp;amp; results.length &amp;gt; 0)
&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp; var result:IdentifyResult = results[0];
&amp;nbsp;&amp;nbsp;&amp;nbsp; var resultGraphic:Graphic = result.feature;
&amp;nbsp;&amp;nbsp;&amp;nbsp; switch (resultGraphic.geometry.type)
&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; case Geometry.MAPPOINT:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; resultGraphic.symbol = smsIdentify;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; case Geometry.POLYLINE:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; resultGraphic.symbol = slsIdentify;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; case Geometry.POLYGON:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; resultGraphic.symbol = sfsIdentify;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp; lastIdentifyResultGraphic = resultGraphic;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; // update clickGraphic (from mouse click to returned feature)
&amp;nbsp;&amp;nbsp;&amp;nbsp; clickGraphic.symbol = new InfoSymbol(); // use default renderer
&amp;nbsp;&amp;nbsp;&amp;nbsp; clickGraphic.attributes = resultGraphic.attributes;
&amp;nbsp;&amp;nbsp; }
&amp;nbsp; }&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is the code I am using for the datagroup &lt;/SPAN&gt;&lt;PRE class="plain" name="code"&gt;&amp;nbsp;&amp;nbsp; [Bindable]
&amp;nbsp; private var resultGraphic:IList;

&amp;lt;s:Scroller visible="false" id="resultlist" width="100%" height="100%"&amp;gt;
&amp;nbsp; &amp;lt;s:DataGroup dataProvider="{resultGraphic}" visible="true"&amp;gt;
&amp;nbsp;&amp;nbsp; &amp;lt;s:layout&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;s:VerticalLayout gap="2" horizontalAlign="justify" useVirtualLayout="true"/&amp;gt;
&amp;nbsp;&amp;nbsp; &amp;lt;/s:layout&amp;gt; 
&amp;nbsp; &amp;lt;/s:DataGroup&amp;gt;
 &amp;lt;/s:Scroller&amp;gt; &lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Unfortunately the data is not being populated in the datagroup. Am I binding the wrong value? Any help would be appreciated&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 23 Jun 2011 12:00:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/bind-identify-results-to-a-datagroup/m-p/602568#M13416</guid>
      <dc:creator>AaronNash</dc:creator>
      <dc:date>2011-06-23T12:00:15Z</dc:date>
    </item>
    <item>
      <title>Re: Bind Identify Results to a datagroup</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/bind-identify-results-to-a-datagroup/m-p/602569#M13417</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;In my application, I've taken the results of the Identify and pushed it into an array, then set the DataGrid's dataProvider to that array. This is part of a larger code for an &lt;/SPAN&gt;&lt;A href="http://ccma.nos.noaa.gov/ecosystems/coastalocean/lis/msp_lis.html" rel="nofollow noopener noreferrer" target="_blank"&gt;application&lt;/A&gt;&lt;SPAN&gt; that takes the IdentifyResults from all the visible layers and puts the results from each layer into a separate tab in an InfoWindow.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; identifyTask.execute(identifyParams, new AsyncResponder(resultFunction, faultFunction, clickGraphic));

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; function resultFunction(results:Array, clickGraphic:Graphic):void
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (results &amp;amp;&amp;amp; results.length &amp;gt; 0)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var resultsArray:Array = [];
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var newDG:DataGrid = new DataGrid;

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; resultsArray.push(result.feature.attributes);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; newDG = new DataGrid;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; newDG.dataProvider = resultsArray;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In reading your post, I was seeing DataGrid instead of DataGroup. However, the dataProvider expects an IList, which could be an ArrayCollection, ArrayList, and&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; XMLListCollection, so you should add your graphic to an array.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:50:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/bind-identify-results-to-a-datagroup/m-p/602569#M13417</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2021-12-12T01:50:33Z</dc:date>
    </item>
    <item>
      <title>Re: Bind Identify Results to a datagroup</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/bind-identify-results-to-a-datagroup/m-p/602570#M13418</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;thanks for the information, I am still playing with the code. Have not been able to figure this out yet. Not sure if the datagroup is the best way to go. The results are being viewed in a mobile android app, that is why i am not using a datagrid&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Jun 2011 13:56:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/bind-identify-results-to-a-datagroup/m-p/602570#M13418</guid>
      <dc:creator>AaronNash</dc:creator>
      <dc:date>2011-06-28T13:56:36Z</dc:date>
    </item>
  </channel>
</rss>

