Delete Shared Parameters in families in the directory
I want to combine them into 1 and based on user input value of “True and False” run 1 of them. Basically like an IF ELSE condition- Where If the condition is True run the first graph, if the condition is false run the second graph.
Is this possible with dynamo? I know that it could be possible by creating custom nodes. Any ideas?
You could leave the nodes in a function state, and pass a either option 1 or option 2 to a Function.Apply node.
You could wrap all of the nodes which perform the operations of option 1 and option 2 inside some custom nodes with an added ‘run’ input, with a ‘not’ value on the test for option 2 but no change for the test on option 1.
You could do a lot of things really; the best ethos will depend upon the actual functions being performed.
So you are looking to either delete the parameters or make new ones, for a large list of family documents?
The answer in this case is to use two graphs for the two completely different set of uses. There is no value in one graph that does both as the time lost in prepping both will be wasted and users are apt to select the wrong option for an input causing extreme data loss, but are not likely to do so with selecting the right graph.
If you really wanted to use this, and again, this is a bad idea from a data fidelity standpoint:
Remove the family document input from everything you have it in now.
Provide all of the other inputs into the create shared parameter node.
Both the creation and deletion nodes would be in a function state now; pass one into the true input of the If node, and the other into the false input.
Place a Function.Apply node where the result from the If node will be the function, and the argument will be the list of family documents.