<?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: StreamLayer: FeatureEffect, FeatureFilter and Definition Expresion Issues in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/streamlayer-featureeffect-featurefilter-and/m-p/1134201#M75934</link>
    <description>&lt;P&gt;Thank you. StreamLayer has&amp;nbsp;&lt;SPAN&gt;definitionExpression property:&amp;nbsp;&lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-StreamLayer.html#definitionExpression" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-StreamLayer.html#definitionExpression&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;I've replaced&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;SPAN&gt;streamLayerView.definitionExpression = null;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;by&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;SPAN&gt;streamLayer.definitionExpression = null;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;But&amp;nbsp;&lt;SPAN&gt;definitionExpression&amp;nbsp;does not&amp;nbsp;work with an StreamLayer.&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Sat, 15 Jan 2022 18:24:37 GMT</pubDate>
    <dc:creator>LuisAntonioRodriguezGonzalez</dc:creator>
    <dc:date>2022-01-15T18:24:37Z</dc:date>
    <item>
      <title>StreamLayer: FeatureEffect, FeatureFilter and Definition Expresion Issues</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/streamlayer-featureeffect-featurefilter-and/m-p/1130036#M75759</link>
      <description>&lt;P&gt;&lt;SPAN&gt;ArcGIS API for JavaScript&amp;nbsp;&lt;A href="https://developers.arcgis.com/javascript/latest/release-notes/" target="_blank" rel="noopener nofollow noreferrer"&gt;4.22&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I have a web app that shows a WebMap with a Stream Layer. This app allows you apply&amp;nbsp;Feature Effect,&amp;nbsp; FeatureFilter or a Definition Expresion on an Stream Layer. Optionally you can set labels on the Stream Layer.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;"esri/layers/support/FeatureEffect",
"esri/layers/support/FeatureFilter"&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I have found these issues:&lt;/SPAN&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;SPAN&gt;FeatureEffect does not work correctly with labelingInfo. After applying a filtered featureEffect, only the labels from the last featureEffect with filter are visible. By setting streamLayerView.featureEffect = null, only the labels from the last filtered featureEffect are displayed. In addition, when you change the FeatureEffect filter, the first filter applied is kept.&lt;/SPAN&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;// Apply FeatureEffect
let featureFilter = new FeatureFilter({
	where: "OriginID = '" + document.getElementById("streamFilterText").value + "'"
  });
if (tipoFiltro === "effect") {
	streamLayerView.featureEffect = new FeatureEffect({
	  filter: featureFilter,
	  excludedEffect: "grayscale(100%) opacity(30%)"
	});
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;SPAN&gt;FeatureFilter does not work correctly with labelingInfo. Firts I apply a FeatureFilter, then I set streamLayerView.featureEffect = null&amp;nbsp; and this code does not work, because the first filter applied is kept. If I apply other attribute filfer, the filter&amp;nbsp;code does not work, because the first filter applied is kept. If I apply other attribute filfer.&lt;/SPAN&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;let featureFilter = new FeatureFilter({
	where: "OriginID = '" + document.getElementById("streamFilterText").value + "'"
  });

  . . .
else if (tipoFiltro === "filter")
	streamLayerView.filter = featureFilter;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;SPAN&gt;definitionExpression does not work. When I set a&amp;nbsp;definitionExpression on the StreamLayer, the points&amp;nbsp;disappear from the map and then new points are showed on the map, but the&amp;nbsp;features are not filtered based on &lt;EM&gt;"OriginID = '" + document.getElementById("streamFilterText").value + "'"&lt;/EM&gt;.&lt;/SPAN&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I attach the source code.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;These are the guidelines to use de web app:&lt;/SPAN&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;SPAN&gt;First, choose one of these options:&lt;BR /&gt;Feature Effect&lt;BR /&gt;Filter&lt;BR /&gt;Definition Expresion&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN&gt;Optionally, you can check Create labels to apply labels on the Stream Layer&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN&gt;Second, click on "Add stream layer" button&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN&gt;Third, write an OriginID in the input, por explample: KLAS, KLAX, N/A, ... and click on "Apply attribute filter" button. By clicking on "Clear filter" you remove the Feature Effect,&amp;nbsp; FeatureFilter or a Definition Expresion&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;&lt;SPAN&gt;If you want change Feature Effect, Filter, Definition Expresion and Create labels options, you have to click on "Remove stream layer" button, select the options and click on "Add stream layer" button&lt;/SPAN&gt;&lt;/LI&gt;&lt;/UL&gt;</description>
      <pubDate>Mon, 03 Jan 2022 15:03:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/streamlayer-featureeffect-featurefilter-and/m-p/1130036#M75759</guid>
      <dc:creator>LuisAntonioRodriguezGonzalez</dc:creator>
      <dc:date>2022-01-03T15:03:31Z</dc:date>
    </item>
    <item>
      <title>Re: StreamLayer: FeatureEffect, FeatureFilter and Definition Expresion Issues</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/streamlayer-featureeffect-featurefilter-and/m-p/1130110#M75763</link>
      <description>&lt;P&gt;Could be related to this issue found here.&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/t5/arcgis-api-for-javascript-questions/feature-effect-and-labeling-issue/m-p/1129839#M75742" target="_blank"&gt;https://community.esri.com/t5/arcgis-api-for-javascript-questions/feature-effect-and-labeling-issue/m-p/1129839#M75742&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 03 Jan 2022 17:51:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/streamlayer-featureeffect-featurefilter-and/m-p/1130110#M75763</guid>
      <dc:creator>ReneRubalcava</dc:creator>
      <dc:date>2022-01-03T17:51:06Z</dc:date>
    </item>
    <item>
      <title>Re: StreamLayer: FeatureEffect, FeatureFilter and Definition Expresion Issues</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/streamlayer-featureeffect-featurefilter-and/m-p/1133052#M75888</link>
      <description>&lt;P&gt;One thing notice from the sample code, in line 233&amp;nbsp;streamLayerView.definitionExpression = null;&lt;/P&gt;&lt;P&gt;streamLayerView does not have&amp;nbsp;definitionExpression property.&amp;nbsp;&lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-views-layers-StreamLayerView.html#properties-summary" target="_blank"&gt;StreamLayerView | API Reference | ArcGIS API for JavaScript 4.22 | ArcGIS Developer&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Jan 2022 19:31:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/streamlayer-featureeffect-featurefilter-and/m-p/1133052#M75888</guid>
      <dc:creator>OliviaZ_Meowth</dc:creator>
      <dc:date>2022-01-12T19:31:35Z</dc:date>
    </item>
    <item>
      <title>Re: StreamLayer: FeatureEffect, FeatureFilter and Definition Expresion Issues</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/streamlayer-featureeffect-featurefilter-and/m-p/1134201#M75934</link>
      <description>&lt;P&gt;Thank you. StreamLayer has&amp;nbsp;&lt;SPAN&gt;definitionExpression property:&amp;nbsp;&lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-StreamLayer.html#definitionExpression" target="_blank"&gt;https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-StreamLayer.html#definitionExpression&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;I've replaced&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;SPAN&gt;streamLayerView.definitionExpression = null;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;by&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;SPAN&gt;streamLayer.definitionExpression = null;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;But&amp;nbsp;&lt;SPAN&gt;definitionExpression&amp;nbsp;does not&amp;nbsp;work with an StreamLayer.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 15 Jan 2022 18:24:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/streamlayer-featureeffect-featurefilter-and/m-p/1134201#M75934</guid>
      <dc:creator>LuisAntonioRodriguezGonzalez</dc:creator>
      <dc:date>2022-01-15T18:24:37Z</dc:date>
    </item>
  </channel>
</rss>

