This site uses different types of cookies, including analytics and functional cookies (its own and from other sites). To change your cookie settings or find out more, click here. If you continue browsing our website, you accept these cookies.
Hi,
I have been working on a workflow that has 5 inputs. The first 4 inputs are standard inputs and will be used in all scenarios but the last input cannot be used in some cases. I want this input to run on a condition.
Condition: I have also used a Count Records tool to form the condition, that is, if the value in Count Records tool is 5 then only run the 5th input file else run the first 4 inputs only.
Now, I'm stuck on how do I connect this condition with the (dynamic) input.
Solved! Go to Solution.
Here's a packaged workflow that contains the workflow, batch macro and one of the "week" files.
I stripped out everything from your original workflow except for the part that reads in the Week 5 data and replaced the Dynamic Input tool with the macro. Image below describes how to set up the connections.
The Macro itself is pretty simple. The Action tool could have been configured to have a hardcoded "5" in the formula, but figured it may be better to add a Text Box to allow you to specify what value it should look for so that this could be used for other use cases.
When the condition is met, the Action tool updates the Detour tool to go Left, which enables the Dynamic Input tool. When it's not, data goes to the Right which samples 0 records and creates the arbitrary "_Condition_Not_Met_" field.
Hope this helps!
Hi,
This is what I was looking for. I cannot express how satisfied I am with this solution, thank you so so much!