<?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: Scripting Tools: Setting parameters so that one or both must be answered in Geoprocessing Questions</title>
    <link>https://community.esri.com/t5/geoprocessing-questions/scripting-tools-setting-parameters-so-that-one-or/m-p/1124676#M26044</link>
    <description>&lt;P&gt;This looks like it should do the trick, thanks!&lt;/P&gt;</description>
    <pubDate>Thu, 09 Dec 2021 23:29:17 GMT</pubDate>
    <dc:creator>AlfredBaldenweck</dc:creator>
    <dc:date>2021-12-09T23:29:17Z</dc:date>
    <item>
      <title>Scripting Tools: Setting parameters so that one or both must be answered</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/scripting-tools-setting-parameters-so-that-one-or/m-p/1124633#M26039</link>
      <description>&lt;P&gt;I'm trying out a script that does two related functions.&lt;/P&gt;&lt;P&gt;I have it set up so that either function can run by itself, or you can run both simultaneously.&lt;/P&gt;&lt;P&gt;My parameters are as follows&lt;/P&gt;&lt;OL class="lia-list-style-type-upper-alpha"&gt;&lt;LI&gt;Input GDB&lt;/LI&gt;&lt;LI&gt;Run Function A? (toggle)&lt;/LI&gt;&lt;LI&gt;Output Location (Function A)&lt;/LI&gt;&lt;LI&gt;Output Location (Function B, essentially acts as its toggle)&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Is there a way to make it so that either B or D, or both of them together, must be answered?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Basically I'm trying to avoid the users running the tool in such a way that neither function runs.&lt;/P&gt;&lt;P&gt;Similarly, is it possible to make Parameters have conditional visibility? Like, C only shows up if B is answered or toggled.&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 09 Dec 2021 22:17:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/scripting-tools-setting-parameters-so-that-one-or/m-p/1124633#M26039</guid>
      <dc:creator>AlfredBaldenweck</dc:creator>
      <dc:date>2021-12-09T22:17:52Z</dc:date>
    </item>
    <item>
      <title>Re: Scripting Tools: Setting parameters so that one or both must be answered</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/scripting-tools-setting-parameters-so-that-one-or/m-p/1124647#M26041</link>
      <description>&lt;P&gt;I use custom toolboxes... easier to see what is going on and minimizes code validation.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="multivalue_parameters.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/29345i5CDD6AC79BB39FEC/image-size/large?v=v2&amp;amp;px=999" role="button" title="multivalue_parameters.png" alt="multivalue_parameters.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;But I am sure you can emulate if you have to use the other toolbox form&lt;/P&gt;</description>
      <pubDate>Thu, 09 Dec 2021 22:35:22 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/scripting-tools-setting-parameters-so-that-one-or/m-p/1124647#M26041</guid>
      <dc:creator>DanPatterson</dc:creator>
      <dc:date>2021-12-09T22:35:22Z</dc:date>
    </item>
    <item>
      <title>Re: Scripting Tools: Setting parameters so that one or both must be answered</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/scripting-tools-setting-parameters-so-that-one-or/m-p/1124656#M26042</link>
      <description>&lt;P&gt;Yes, I'm using that, too.&lt;/P&gt;&lt;P&gt;I'm looking to make it so either Parameter B or Parameter D must be answered.&lt;BR /&gt;It doesn't matter which one of them is answered.&lt;/P&gt;&lt;TABLE border="1" width="100%"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="50%"&gt;Parameter A&lt;/TD&gt;&lt;TD width="50%"&gt;Required&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;&lt;P&gt;Parameter B (optional)&lt;/P&gt;&lt;P&gt;OR&lt;/P&gt;&lt;P&gt;Parameter D (optional)&lt;/P&gt;&lt;/TD&gt;&lt;TD width="50%"&gt;Required&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="50%"&gt;Parameter C&lt;/TD&gt;&lt;TD width="50%"&gt;Required&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;</description>
      <pubDate>Thu, 09 Dec 2021 22:42:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/scripting-tools-setting-parameters-so-that-one-or/m-p/1124656#M26042</guid>
      <dc:creator>AlfredBaldenweck</dc:creator>
      <dc:date>2021-12-09T22:42:34Z</dc:date>
    </item>
    <item>
      <title>Re: Scripting Tools: Setting parameters so that one or both must be answered</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/scripting-tools-setting-parameters-so-that-one-or/m-p/1124662#M26043</link>
      <description>&lt;P&gt;Hi Alfred,&lt;/P&gt;&lt;P&gt;What you are after is Script Tool Paramter&amp;nbsp;&lt;A href="https://pro.arcgis.com/en/pro-app/latest/arcpy/geoprocessing_and_python/customizing-script-tool-behavior.htm" target="_self"&gt;Behaviour.&lt;/A&gt;&amp;nbsp;You can set the Parameter[i].enabled = True/False to enable disable a parameter. You can apply a condition on Parameter B's values to dynamically enable/disable Parameters C/D.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The logic would be something like the below:&lt;/P&gt;&lt;P&gt;Parameter B should be a MultiValue list with your selectable (filter) options: &lt;EM&gt;Function A&lt;/EM&gt;, &lt;EM&gt;Function B&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Parameter C has a dependency on Parameter B and is&amp;nbsp;&lt;EM&gt;enabled&lt;/EM&gt; when Parameter B has&amp;nbsp;&lt;EM&gt;Function A&lt;/EM&gt; in its list of values.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Similarly, Parameter D has a dependency on Parameter B and is &lt;I&gt;enabled&amp;nbsp;&lt;/I&gt;when Parameter B has&amp;nbsp;&lt;EM&gt;Function B&lt;/EM&gt; in its list of values.&lt;/P&gt;&lt;P&gt;If both&amp;nbsp;&lt;EM&gt;Function A&lt;/EM&gt; and &lt;EM&gt;Function B&lt;/EM&gt; are selected in Parameter B, both Parameter C and D will be selectable.&lt;/P&gt;&lt;P&gt;Hope this helps!&lt;/P&gt;</description>
      <pubDate>Thu, 09 Dec 2021 22:52:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/scripting-tools-setting-parameters-so-that-one-or/m-p/1124662#M26043</guid>
      <dc:creator>LongDinh</dc:creator>
      <dc:date>2021-12-09T22:52:29Z</dc:date>
    </item>
    <item>
      <title>Re: Scripting Tools: Setting parameters so that one or both must be answered</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/scripting-tools-setting-parameters-so-that-one-or/m-p/1124676#M26044</link>
      <description>&lt;P&gt;This looks like it should do the trick, thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 09 Dec 2021 23:29:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/scripting-tools-setting-parameters-so-that-one-or/m-p/1124676#M26044</guid>
      <dc:creator>AlfredBaldenweck</dc:creator>
      <dc:date>2021-12-09T23:29:17Z</dc:date>
    </item>
  </channel>
</rss>

