
Originally Posted by
c.f.
Seriously, I cannot recommend this. If you want to create a screen switch function every time you create a screen or have a screen switch function created for all your screens: consider to create an Editor wizard or service, which creates the screen switch functions for you.
___
It is possible to change the screen name in a dynamic property.
Example (Wizard):
´´´Code
public void Run(IProject context, IBehavior behavior)
{
var function = context.FunctionCollection["GenericScreenSwitch"];
var propertyPathScreenParameter = "PictSwitch[0].Picture";
var targetScreenName = "Screen2";
function.SetDynamicProperty(propertyPathScreenPara meter,targetScreenName);
function.Execute();
}
´´´End
Also remark, that some of the screen switch functions have filters included. You have to take care of them yourself.