<?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: Fields of Feature Layer in ArcGIS API for Flex Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559665#M12596</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;You need to wait for the feature layer to load before you can access the fields.&amp;nbsp;&amp;nbsp; So you need to add a LayerEvent.LOAD listener to fLayer.&amp;nbsp; &lt;BR /&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;That did it... thanks!!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 02 Nov 2010 11:51:16 GMT</pubDate>
    <dc:creator>PaulSchneider</dc:creator>
    <dc:date>2010-11-02T11:51:16Z</dc:date>
    <item>
      <title>Fields of Feature Layer</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559661#M12592</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I an trying to add the fields of a feature layer to a combo box and am running into what seems like a silly simple problem.&amp;nbsp;&amp;nbsp; I have created the FeatureLayer object but when I try to access the fields I get nothing.&amp;nbsp; Below is my code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;var fLayer:FeatureLayer = new FeatureLayer("&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/SanFrancisco/311Incidents/MapServer/1" rel="nofollow" target="_blank"&gt;http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/SanFrancisco/311Incidents/MapServer/1&lt;/A&gt;&lt;SPAN&gt;");&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;if (fLayer)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[INDENT]var fldArr:Array = fLayer.layerDetails.fields;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Alert.show(fldArr.toString());&amp;nbsp; //....NOTHING!!....&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;/* if working... do this...&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;var fldAL:ArrayList = new ArrayList(fldArr);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;cboField.dataProvider = fldAL;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; */[/INDENT]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any thoughts?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Oct 2010 14:56:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559661#M12592</guid>
      <dc:creator>PaulSchneider</dc:creator>
      <dc:date>2010-10-29T14:56:49Z</dc:date>
    </item>
    <item>
      <title>Re: Fields of Feature Layer</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559662#M12593</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;It looks like you are trying to get the fields from a table, not a feature layer.&amp;nbsp; The layer with an index of 1 is a table, try using the layer with an index of 0 instead.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If you do want to get the fields from the table with index 1, then you need to use fLayer.tableDetails.fields instead of fLayer.layerDetails.fields.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Oct 2010 15:28:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559662#M12593</guid>
      <dc:creator>JustinGreco</dc:creator>
      <dc:date>2010-10-29T15:28:02Z</dc:date>
    </item>
    <item>
      <title>Re: Fields of Feature Layer</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559663#M12594</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;It looks like you are trying to get the fields from a table, not a feature layer.&amp;nbsp; The layer with an index of 1 is a table, try using the layer with an index of 0 instead.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Still nothing...&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Oct 2010 15:32:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559663#M12594</guid>
      <dc:creator>PaulSchneider</dc:creator>
      <dc:date>2010-10-29T15:32:36Z</dc:date>
    </item>
    <item>
      <title>Re: Fields of Feature Layer</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559664#M12595</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You need to wait for the feature layer to load before you can access the fields.&amp;nbsp;&amp;nbsp; So you need to add a LayerEvent.LOAD listener to fLayer.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Also if you want to get the field names, you need to loop through each field and push the name value to the array.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Oct 2010 15:43:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559664#M12595</guid>
      <dc:creator>JustinGreco</dc:creator>
      <dc:date>2010-10-29T15:43:57Z</dc:date>
    </item>
    <item>
      <title>Re: Fields of Feature Layer</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559665#M12596</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;You need to wait for the feature layer to load before you can access the fields.&amp;nbsp;&amp;nbsp; So you need to add a LayerEvent.LOAD listener to fLayer.&amp;nbsp; &lt;BR /&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;That did it... thanks!!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Nov 2010 11:51:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559665#M12596</guid>
      <dc:creator>PaulSchneider</dc:creator>
      <dc:date>2010-11-02T11:51:16Z</dc:date>
    </item>
    <item>
      <title>Re: Fields of Feature Layer</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559666#M12597</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;That did it... thanks!!&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;hello &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have the same pb when i try this Alert.show(fldArr.toString());&amp;nbsp; it's not working &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;'featurelayer0' .&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;thank you for the help&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Apr 2013 11:22:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559666#M12597</guid>
      <dc:creator>lifeEsri</dc:creator>
      <dc:date>2013-04-01T11:22:14Z</dc:date>
    </item>
    <item>
      <title>Re: Fields of Feature Layer</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559667#M12598</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;life Esri,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; You need to use &lt;/SPAN&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;import mx.utils.ObjectUtil;
Alert.show(&lt;SPAN style="color:#FF0000;"&gt;ObjectUtil.toString&lt;/SPAN&gt;(fldArr));&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 00:09:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559667#M12598</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2021-12-12T00:09:31Z</dc:date>
    </item>
    <item>
      <title>Re: Fields of Feature Layer</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559668#M12599</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;life Esri,&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; You need to use &lt;PRE class="lia-code-sample line-numbers language-none"&gt;import mx.utils.ObjectUtil;
Alert.show(&lt;SPAN style="color:#FF0000;"&gt;ObjectUtil.toString&lt;/SPAN&gt;(fldArr));&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;thank you but still nothing ..&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;ok my pb is &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I would like to create a combobox that listed the layers of my service in arcgis server and publish and create another combobox which contains the list of fields in each layer selected in the first combobox&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;and thank you in advance.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 00:09:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/fields-of-feature-layer/m-p/559668#M12599</guid>
      <dc:creator>lifeEsri</dc:creator>
      <dc:date>2021-12-12T00:09:33Z</dc:date>
    </item>
  </channel>
</rss>

