IF statement with Freezing

Hi everyone,
I want to make if statement but:
if it’s true - do something
if it’s false - freeze all functions later on (don’t do anything after that node).

I try not to create unnecessary warnings in Dynamo.
Do you have any clues for me?

It can be because of an infinitive loop. Can you share a screenshot, what you trying to do?

Try and look in to the tool.runme node from Steamnodes? Maybe that is what you are looking for :slight_smile:

I get 0 when False, it’s not it :frowning:

I want code to do this when TRUE and when False, do nothing and not get warnings

Try to connect a code block with null or Transaction.End to false

It gives warning.

Dynamo executes all nodes before commiting the transaction. It’s not a question of whether you can “freeze” unwanted nodes but how you can run them without errors. Most nodes will function with empty lists but error with null values. It is possible to force empty lists in a situation like this, but usually means having to include checks for all nodes that prevent nulls and provide empty lists. If you decide to go this route I highly recommend wrapping as much as possible into a code block.

You can also wrap large parts of your graph into custom nodes. Internal warnings will not show for a custom node so you just have to correct the final output.

2 Likes

Thanks a lot for your answer