More possibilities for if statements

Hi Chris,

I am facing the situation that I have to go through quite some related variants of tasks.
It would be great to be able to include include statements and python code also on the highest level based on an if, so I can set a variable at the top of the script that turns on and off later includes or scripts. This will make everything less error-prone and redundant.

I assume there’s a strong reason why this functionality is not already present?

Thanks

Alina

Hi Alina,

This is something I want, too. The only reason it isn’t already there is that I haven’t gotten around to adding it. I still plan to do so, but I don’t know when.

Chris

Ok, please let me know when this is on the horizon, everything is a lot messier without it :blush:

Hi Alina,

As of the current MWorks nightly build, MWEL supports conditional inclusion, which I believe provides a solution for this issue. The docs explain how it works in detail. If you have any questions, please let me know.

Cheers,
Chris