<?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 Identifying features in layers when users tap on map, but when layers not visible? in ArcGIS Runtime SDK for iOS Questions</title>
    <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifying-features-in-layers-when-users-tap-on/m-p/1036907#M6954</link>
    <description>&lt;P&gt;Hi, I'd like to use the &lt;FONT face="courier new,courier"&gt;AGSMapView&lt;/FONT&gt; method &lt;FONT face="courier new,courier"&gt;identifyLayers()&lt;/FONT&gt; to determine what features are at a user-tapped map location. However, I noticed that only visible layers (whose &lt;FONT face="courier new,courier"&gt;isVisible&lt;/FONT&gt; property are set to true) return features.&lt;/P&gt;&lt;P&gt;Is this the expected behavior?&amp;nbsp; In my case, I'd like to use &lt;FONT face="courier new,courier"&gt;identifyLayers()&lt;/FONT&gt; to get features from "invisible" layers (whose &lt;FONT face="courier new,courier"&gt;isVisible&lt;/FONT&gt; property are set to false), but the closest I can get to this behavior is to set all layers visible, and reset the layer renderers and disable layer labels. Unfortunately, resetting the layer renderers and disabling the layer labels doesn't hide the intrinsic layer features, so the layers are visible.&lt;/P&gt;&lt;P&gt;Is there a way to use &lt;FONT face="courier new,courier"&gt;identifyLayers()&lt;/FONT&gt;&amp;nbsp;to get features for map layers that aren't visible?&lt;/P&gt;</description>
    <pubDate>Mon, 15 Mar 2021 22:21:37 GMT</pubDate>
    <dc:creator>MichaelHorii</dc:creator>
    <dc:date>2021-03-15T22:21:37Z</dc:date>
    <item>
      <title>Identifying features in layers when users tap on map, but when layers not visible?</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifying-features-in-layers-when-users-tap-on/m-p/1036907#M6954</link>
      <description>&lt;P&gt;Hi, I'd like to use the &lt;FONT face="courier new,courier"&gt;AGSMapView&lt;/FONT&gt; method &lt;FONT face="courier new,courier"&gt;identifyLayers()&lt;/FONT&gt; to determine what features are at a user-tapped map location. However, I noticed that only visible layers (whose &lt;FONT face="courier new,courier"&gt;isVisible&lt;/FONT&gt; property are set to true) return features.&lt;/P&gt;&lt;P&gt;Is this the expected behavior?&amp;nbsp; In my case, I'd like to use &lt;FONT face="courier new,courier"&gt;identifyLayers()&lt;/FONT&gt; to get features from "invisible" layers (whose &lt;FONT face="courier new,courier"&gt;isVisible&lt;/FONT&gt; property are set to false), but the closest I can get to this behavior is to set all layers visible, and reset the layer renderers and disable layer labels. Unfortunately, resetting the layer renderers and disabling the layer labels doesn't hide the intrinsic layer features, so the layers are visible.&lt;/P&gt;&lt;P&gt;Is there a way to use &lt;FONT face="courier new,courier"&gt;identifyLayers()&lt;/FONT&gt;&amp;nbsp;to get features for map layers that aren't visible?&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 22:21:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifying-features-in-layers-when-users-tap-on/m-p/1036907#M6954</guid>
      <dc:creator>MichaelHorii</dc:creator>
      <dc:date>2021-03-15T22:21:37Z</dc:date>
    </item>
    <item>
      <title>Re: Identifying features in layers when users tap on map, but when layers not visible?</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifying-features-in-layers-when-users-tap-on/m-p/1036928#M6955</link>
      <description>&lt;P&gt;Hi.&lt;/P&gt;&lt;P&gt;Identify is deliberately meant to be a user-driven operation, hence it works with visible layers.&lt;/P&gt;&lt;P&gt;However, you might be able to get the effect you want by setting the &lt;A href="https://developers.arcgis.com/ios/api-reference/interface_a_g_s_layer.html#a6ea8ae3144a242f4b0c4e23601752362" target="_self"&gt;&lt;STRONG&gt;opacity&lt;/STRONG&gt;&lt;/A&gt; of each "invisible" layer to 0, set the isVisible property to true, perform the identify, and then revert the opacity back to 1.0 and the isVisible to false. The layer will technically be visible, but you won't be able to see it. You might need to set the opacity to something very small (e.g. 0.001) but I think 0 will work.&lt;/P&gt;&lt;P&gt;The other way to do this is to make queries against each individual layer's featureTable (that's what Identify does behind the scenes) and synchronize the responses with a &lt;A href="https://developer.apple.com/documentation/dispatch/dispatchgroup" target="_self"&gt;&lt;STRONG&gt;DispatchGroup&lt;/STRONG&gt;&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;Let me know if the opacity trick works.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 23:11:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifying-features-in-layers-when-users-tap-on/m-p/1036928#M6955</guid>
      <dc:creator>Nicholas-Furness</dc:creator>
      <dc:date>2021-03-15T23:11:15Z</dc:date>
    </item>
    <item>
      <title>Re: Identifying features in layers when users tap on map, but when layers not visible?</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifying-features-in-layers-when-users-tap-on/m-p/1036937#M6956</link>
      <description>&lt;P&gt;Great, thank you! The opacity trick works like a charm.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 23:31:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-ios-questions/identifying-features-in-layers-when-users-tap-on/m-p/1036937#M6956</guid>
      <dc:creator>MichaelHorii</dc:creator>
      <dc:date>2021-03-15T23:31:03Z</dc:date>
    </item>
  </channel>
</rss>

