<?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: Trouble accessing feature layer in WAB (DE) in ArcGIS Web AppBuilder Questions</title>
    <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567639#M15171</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Joel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ConstructionSvcs_scratch_6492_6 means that the layer is a sub layer of a ArcGISDynamicMapServiceLayer so though the layer is added to the map an&amp;nbsp;&lt;SPAN&gt;ArcGISDynamicMapServiceLayer&amp;nbsp;sublayer is not an actual layer that can have a click event. An&amp;nbsp;ArcGISDynamicMapServiceLayer&amp;nbsp;is just an image returned from the server and thus no actual geometry is returned&amp;nbsp;to the client&amp;nbsp;that could be used for a click event.&amp;nbsp; You need to add the layer as a Feature layer so that the client&amp;nbsp;is getting actual geometries returned to it.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 17 May 2019 21:05:33 GMT</pubDate>
    <dc:creator>RobertScheitlin__GISP</dc:creator>
    <dc:date>2019-05-17T21:05:33Z</dc:date>
    <item>
      <title>Trouble accessing feature layer in WAB (DE)</title>
      <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567634#M15166</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm having a little trouble accessing my feature layer in the Web Appbuilder app. If I did the following outside of WAB, just in a testing JS 3.x environment, it would work.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;lt;script&amp;gt;&lt;/P&gt;&lt;DIV style="color: #fcfcfa; background-color: #2d2a2e; font-weight: normal; font-size: 14px;"&gt;&lt;DIV&gt;&lt;SPAN style="color: #78dce8;"&gt;&amp;nbsp;var&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; myFL &lt;/SPAN&gt;&lt;SPAN style="color: #ff6188;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #ff6188;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #a9dc76;"&gt;FeatureLayer&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;https://blahblah/MapServer/6&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;{&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt;&amp;nbsp;mode&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; FeatureLayer&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #ab9df2;"&gt;MODE_AUTO&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt;&amp;nbsp;outFields&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;&lt;LI&gt;&lt;/LI&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt;&amp;nbsp;id&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;myParcels&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #939293;"&gt;&amp;nbsp;})&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt;&amp;nbsp;map&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #a9dc76;"&gt;addLayer&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt;myFL&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt;&amp;nbsp;myFL&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #a9dc76;"&gt;on&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;click&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #78dce8;"&gt;function&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #fc9867;"&gt;evt&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;)&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;{&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #78dce8;"&gt;&amp;nbsp;var&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; geom &lt;/SPAN&gt;&lt;SPAN style="color: #ff6188;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; evt&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt;graphic&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt;geometry&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #78dce8;"&gt;&amp;nbsp;console&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #a9dc76;"&gt;log&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt;geom&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;lt;/script&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But in WAB, myFL already exists in there, so if I do map.addLayer(myFL), it's adding it a second time, but that's the only way I can successfully return anything on a click event.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I do the following in WAB, not adding the layer (because it's already in the map and I don't want it twice), I can't return anything on the click event.&amp;nbsp;I'm not sure what I'm missing that I can't return anything?? I feel like I've tried everything to access this layer, I've tried map.getLayer(id), and that didn't work. Not sure why it isn't working...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;script&amp;gt;&lt;/P&gt;&lt;DIV style="color: #fcfcfa; background-color: #2d2a2e; font-weight: normal; font-size: 14px;"&gt;&lt;DIV&gt;&lt;SPAN style="color: #939293;"&gt;{&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff6188;"&gt;&amp;nbsp;return&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #ff6188;"&gt;declare&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt;BaseWidget&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;{&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #939293;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #727072;"&gt;//Derive from BaseWidget.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt;&amp;nbsp; baseClass&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;jimu-widget-myWidget&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt;&amp;nbsp; isActive&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #ab9df2;"&gt;true&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #a9dc76;"&gt;&amp;nbsp; startup&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #78dce8;"&gt;function&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;()&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;{&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #c1c0c0;"&gt;&amp;nbsp; this&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #a9dc76;"&gt;inherited&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #ab9df2;"&gt;arguments&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #c1c0c0;"&gt;&amp;nbsp; this&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt;myFL &lt;/SPAN&gt;&lt;SPAN style="color: #ff6188;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #ff6188;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #a9dc76;"&gt;FeatureLayer&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;https://blahblah/MapServer/6&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,{&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt;&amp;nbsp; outFields&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;[&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;*&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;]})&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;},&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #a9dc76;"&gt;&amp;nbsp; onOpen&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;:&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #78dce8;"&gt;function&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(){&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #c1c0c0;"&gt;&amp;nbsp; this&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt;myFL&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #a9dc76;"&gt;on&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;click&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #78dce8;"&gt;function&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #fc9867;"&gt;evt&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;){&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #78dce8;"&gt;&amp;nbsp; var&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; geom &lt;/SPAN&gt;&lt;SPAN style="color: #ff6188;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; evt&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt;graphic&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt;geometry&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #78dce8;"&gt;&amp;nbsp; console&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #a9dc76;"&gt;log&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt;geom&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #939293;"&gt;&amp;nbsp; })&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #939293;"&gt;&amp;nbsp;}&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #939293;"&gt;&amp;nbsp;});&lt;/SPAN&gt;&lt;SPAN style="color: #fcfcfa;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #939293;"&gt;&amp;nbsp;});&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;lt;/script&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 May 2019 16:38:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567634#M15166</guid>
      <dc:creator>JoelPerkins</dc:creator>
      <dc:date>2019-05-17T16:38:52Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble accessing feature layer in WAB (DE)</title>
      <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567635#M15167</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Joel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; If the layer is already added to the map then you just need to get a reference to the layer and add your on click method to the existing layer in the map.&lt;/P&gt;&lt;P&gt;var myfl = this.map.getLayer("your layer id");&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 May 2019 17:08:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567635#M15167</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2019-05-17T17:08:45Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble accessing feature layer in WAB (DE)</title>
      <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567636#M15168</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Robert,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was trying that before, the only thing I can think of is that I'm not getting the right ID.&amp;nbsp;&lt;/P&gt;&lt;P&gt;in getLayer(ID), would it be "6" here? or "Taxlots"? Neither work, but I want to make sure I'm at least getting the right one. Does it matter that it's in a group layer, and it's a child of Landbase?&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="image-1 jive-image j-img-original" src="https://community.esri.com/legacyfs/online/447915_layer.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 May 2019 19:05:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567636#M15168</guid>
      <dc:creator>JoelPerkins</dc:creator>
      <dc:date>2019-05-17T19:05:43Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble accessing feature layer in WAB (DE)</title>
      <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567637#M15169</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Joel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;Nope neither of those are the id as you have seen. The easyest way to find the layers ID is to open the layerlist widget and right click on the layer in your layerlist and choose inspect or inspect element. It will look something like this:&lt;/P&gt;&lt;PRE class="line-numbers language-markup"&gt;&lt;CODE&gt;&lt;SPAN class="token tag"&gt;&lt;SPAN class="token tag"&gt;&lt;SPAN class="punctuation token"&gt;&amp;lt;&lt;/SPAN&gt;div&lt;/SPAN&gt; &lt;SPAN class="attr-name token"&gt;class&lt;/SPAN&gt;&lt;SPAN class="attr-value token"&gt;&lt;SPAN class="punctuation token"&gt;=&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;"&lt;/SPAN&gt;layer-title-div-ParcelViewerWM_1607 div-content jimu-float-leading &lt;SPAN class="punctuation token"&gt;"&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt;Parcel Data&lt;SPAN class="token tag"&gt;&lt;SPAN class="token tag"&gt;&lt;SPAN class="punctuation token"&gt;&amp;lt;/&lt;/SPAN&gt;div&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;The layers id is ParcelViewerWM_1607&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 May 2019 19:33:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567637#M15169</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2019-05-17T19:33:40Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble accessing feature layer in WAB (DE)</title>
      <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567638#M15170</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ok thanks,&amp;nbsp;&lt;/P&gt;&lt;P&gt;Just so I'm not totally going insane here, looking at my code, is there any thing that jumps out at you with the onOpen method?&lt;/P&gt;&lt;P&gt;I keep getting this error, and I don't understand why.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TypeError: Unable to get property 'on' of undefined or null reference&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;lt;script&amp;gt;&amp;nbsp;&lt;/P&gt;&lt;DIV style="color: #fcfcfa; background-color: #2d2a2e; font-weight: normal; font-size: 14px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;DIV style="font-weight: normal;"&gt;&lt;DIV&gt;&lt;SPAN style="color: #a9dc76;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;define&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;([&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;dojo/_base/declare&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;jimu/BaseWidget&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;dojo/on&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;dojo/domReady!&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;],&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #78dce8;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;function&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #fc9867;"&gt;declare&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #fc9867;"&gt;BaseWidget&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #fc9867;"&gt;on&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;)&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;{&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff6188;"&gt;&amp;nbsp; &amp;nbsp; return&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #ff6188;"&gt;declare&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;([&lt;/SPAN&gt;&lt;SPAN&gt;BaseWidget&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;],&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;{&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; baseClass&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;:&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;jimu-widget-myWidget&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;'&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #a9dc76;"&gt;&amp;nbsp; &amp;nbsp; onOpen&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;:&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #78dce8;"&gt;function&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(){&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #c1c0c0;"&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;myFL &lt;/SPAN&gt;&lt;SPAN style="color: #ff6188;"&gt;=&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #c1c0c0;"&gt;this&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;map&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #a9dc76;"&gt;getLayer&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;ConstructionSvcs_scratch_6492_6&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #c1c0c0;"&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;myFL&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #a9dc76;"&gt;on&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #ffd866;"&gt;click&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;,&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #78dce8;"&gt;function&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #fc9867;"&gt;e&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;){&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #78dce8;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; console&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="color: #a9dc76;"&gt;log&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;e&lt;/SPAN&gt;&lt;SPAN style="color: #939293;"&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #939293;"&gt;&amp;nbsp; &amp;nbsp; })&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #939293;"&gt;&amp;nbsp; &amp;nbsp;},&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN style="color: #939293;"&gt;&amp;nbsp; &amp;nbsp;});&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #939293;"&gt;&amp;nbsp; &amp;nbsp;});&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV style="color: #fcfcfa; background-color: #2d2a2e; font-weight: normal; font-size: 14px;"&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp; &amp;lt;/script&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 May 2019 20:45:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567638#M15170</guid>
      <dc:creator>JoelPerkins</dc:creator>
      <dc:date>2019-05-17T20:45:24Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble accessing feature layer in WAB (DE)</title>
      <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567639#M15171</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Joel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ConstructionSvcs_scratch_6492_6 means that the layer is a sub layer of a ArcGISDynamicMapServiceLayer so though the layer is added to the map an&amp;nbsp;&lt;SPAN&gt;ArcGISDynamicMapServiceLayer&amp;nbsp;sublayer is not an actual layer that can have a click event. An&amp;nbsp;ArcGISDynamicMapServiceLayer&amp;nbsp;is just an image returned from the server and thus no actual geometry is returned&amp;nbsp;to the client&amp;nbsp;that could be used for a click event.&amp;nbsp; You need to add the layer as a Feature layer so that the client&amp;nbsp;is getting actual geometries returned to it.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 May 2019 21:05:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567639#M15171</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2019-05-17T21:05:33Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble accessing feature layer in WAB (DE)</title>
      <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567640#M15172</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;OK, that was the issue. Thanks Robert!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 May 2019 22:23:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-web-appbuilder-questions/trouble-accessing-feature-layer-in-wab-de/m-p/567640#M15172</guid>
      <dc:creator>JoelPerkins</dc:creator>
      <dc:date>2019-05-17T22:23:33Z</dc:date>
    </item>
  </channel>
</rss>

