<?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: Identify only visible features (layerdefinition) in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/identify-only-visible-features-layerdefinition/m-p/185173#M17209</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You have to first set idParams.layerDefinitions to an empty array and then populate the array. Each item in that array corresponds to a single layer definition. An item's index in an array corresponds to the layer index to which a layer definition applies.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The simplest way to use layer definitions on an identifyParameters object while still having readable code is the following:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;// create layerDefinitions as an empty array&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;idParams.layerDefinitions = [];&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;// populate only the array indexes which need to apply a definition query&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;idParams.layerDefinitions[2] = "PSTLADDRESS = '4686 Brightmore Rd'"&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 05 Dec 2011 04:36:06 GMT</pubDate>
    <dc:creator>RahulMetangale</dc:creator>
    <dc:date>2011-12-05T04:36:06Z</dc:date>
    <item>
      <title>Identify only visible features (layerdefinition)</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/identify-only-visible-features-layerdefinition/m-p/185171#M17207</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm using a layer definition to display only a subset of features. When I then click on a point to identify it however, it frequently brings up a nearby 'invisible' feature - one that was excluded by the layer definition.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I've read this thread: &lt;/SPAN&gt;&lt;A href="http://forums.arcgis.com/threads/39250-Identify-Task-identifys-also-invisble-features-(LayerDefinition)"&gt;http://forums.arcgis.com/threads/39250-Identify-Task-identifys-also-invisble-features-(LayerDefinition)&lt;/A&gt;&lt;SPAN&gt; but am still having no luck.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Anybody have an example of applying the identifyparams.layerdefinitions that is more complete than the reference snippet? Or another method of identifying only visible features?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Dec 2011 17:57:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/identify-only-visible-features-layerdefinition/m-p/185171#M17207</guid>
      <dc:creator>MikeKillion</dc:creator>
      <dc:date>2011-12-02T17:57:40Z</dc:date>
    </item>
    <item>
      <title>Re: Identify only visible features (layerdefinition)</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/identify-only-visible-features-layerdefinition/m-p/185172#M17208</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Mike,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I haven't tried this but from the &lt;/SPAN&gt;&lt;A href="http://help.arcgis.com/en/webapi/javascript/arcgis/help/jsapi_start.htm#jsapi/identifyparameters.htm"&gt;documentation&lt;/A&gt;&lt;SPAN&gt; it seems you need to apply the same layer definition to the IdentifyParameters as you apply to the layer.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Can you post the code showing how you're applying the definition to your layer? It should then be possible to recommend how to do it in the IdentifyParameters.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Steve&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Dec 2011 04:03:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/identify-only-visible-features-layerdefinition/m-p/185172#M17208</guid>
      <dc:creator>StephenLead</dc:creator>
      <dc:date>2011-12-05T04:03:56Z</dc:date>
    </item>
    <item>
      <title>Re: Identify only visible features (layerdefinition)</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/identify-only-visible-features-layerdefinition/m-p/185173#M17209</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You have to first set idParams.layerDefinitions to an empty array and then populate the array. Each item in that array corresponds to a single layer definition. An item's index in an array corresponds to the layer index to which a layer definition applies.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The simplest way to use layer definitions on an identifyParameters object while still having readable code is the following:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;// create layerDefinitions as an empty array&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;idParams.layerDefinitions = [];&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;// populate only the array indexes which need to apply a definition query&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;idParams.layerDefinitions[2] = "PSTLADDRESS = '4686 Brightmore Rd'"&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Dec 2011 04:36:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/identify-only-visible-features-layerdefinition/m-p/185173#M17209</guid>
      <dc:creator>RahulMetangale</dc:creator>
      <dc:date>2011-12-05T04:36:06Z</dc:date>
    </item>
    <item>
      <title>Re: Identify only visible features (layerdefinition)</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/identify-only-visible-features-layerdefinition/m-p/185174#M17210</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi, Rahul&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Is this also applicable to ArcGIS Server 9.3.1? I tried with your sample servers and it worked, but with my 9.3.1 ArcGIS Server I couldn't make it work.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there any alternative?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks in advance,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Santiago&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Jul 2012 09:17:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/identify-only-visible-features-layerdefinition/m-p/185174#M17210</guid>
      <dc:creator>SantiagoLastra</dc:creator>
      <dc:date>2012-07-05T09:17:56Z</dc:date>
    </item>
  </channel>
</rss>

