User Defined Methods in Chart / SFC

Is it possible to create user define methods inside an SFC?

In my current situation an alternative would be to call a method in python module I have located on the server in C:\Program Files\Inductive Automation\Ignition\user-lib\pylib\ my_module

I’m trying to get access to this in an SFC Transition using runScript(“my_module.some_method”, …) but I get an error saying “…in NameError: name ‘my_module’ is not defined…”

Thanks,

Rick

Such modules have to be imported before use, and runScript offers no method to do so. You’ll have to write a stub function in a project or shared module that calls that function on runScript’s behalf.