<?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 Geoprocessing.ExecuteToolAsync with Definition Query in ArcGIS Pro SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/geoprocessing-executetoolasync-with-definition/m-p/1147790#M7845</link>
    <description>&lt;P&gt;I noticed my code that runs&amp;nbsp;Geoprocessing.ExecuteToolAsync for analysis.intersect wasn't getting the layer's definition query.&amp;nbsp;&lt;/P&gt;&lt;P&gt;after running something like this i'm am getting the intersect results layer but it is not changing when I add a definition query to the layers. How do I pass this layer with the definition query applied into&amp;nbsp;Geoprocessing.ExecuteToolAsync?&lt;/P&gt;&lt;LI-CODE lang="c"&gt;var lyrRoute = map.GetLayersAsFlattenedList().OfType&amp;lt;FeatureLayer&amp;gt;().Where(l =&amp;gt; l.Parent.ToString() == "LinearRoute" &amp;amp;&amp;amp; l.IsVisible == true).FirstOrDefault();

inputList.Add(lyrRoute.Name);
inputList.Add(lyr.Name);
var args = Geoprocessing.MakeValueArray(inputList, outputPath, "", "", "POINT");
string toolPath = "analysis.Intersect";
var result = await Geoprocessing.ExecuteToolAsync(toolPath, args, environments);&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 24 Feb 2022 23:08:29 GMT</pubDate>
    <dc:creator>VastBeta</dc:creator>
    <dc:date>2022-02-24T23:08:29Z</dc:date>
    <item>
      <title>Geoprocessing.ExecuteToolAsync with Definition Query</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/geoprocessing-executetoolasync-with-definition/m-p/1147790#M7845</link>
      <description>&lt;P&gt;I noticed my code that runs&amp;nbsp;Geoprocessing.ExecuteToolAsync for analysis.intersect wasn't getting the layer's definition query.&amp;nbsp;&lt;/P&gt;&lt;P&gt;after running something like this i'm am getting the intersect results layer but it is not changing when I add a definition query to the layers. How do I pass this layer with the definition query applied into&amp;nbsp;Geoprocessing.ExecuteToolAsync?&lt;/P&gt;&lt;LI-CODE lang="c"&gt;var lyrRoute = map.GetLayersAsFlattenedList().OfType&amp;lt;FeatureLayer&amp;gt;().Where(l =&amp;gt; l.Parent.ToString() == "LinearRoute" &amp;amp;&amp;amp; l.IsVisible == true).FirstOrDefault();

inputList.Add(lyrRoute.Name);
inputList.Add(lyr.Name);
var args = Geoprocessing.MakeValueArray(inputList, outputPath, "", "", "POINT");
string toolPath = "analysis.Intersect";
var result = await Geoprocessing.ExecuteToolAsync(toolPath, args, environments);&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Feb 2022 23:08:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/geoprocessing-executetoolasync-with-definition/m-p/1147790#M7845</guid>
      <dc:creator>VastBeta</dc:creator>
      <dc:date>2022-02-24T23:08:29Z</dc:date>
    </item>
  </channel>
</rss>

