When executing the test suite, Ranorex runs the Program class. However, when running Code Modules individually in isolation, they appear to be executed directly. I have code which I want to be executed in either case. But I cannot find a decent place to but it.
One option is to have Code Modules inherit from a base class which executes such code. Thereby, base class code will be executed when a code module is run in isolation and also when it is run from within the test suite. However, this appears unintuitive, as I hijack the inheritance concept in order to solve an execution-order problem.