You can use the Alf editor to create an Alf body for the effect Behavior of a Transition in a State Machine or to edit the existing Alf body of an effect Behavior.
To create an Alf body for an effect Behavior
- Select the Transition (in the Model Browser or as represented on a State Machine diagram) and open the Alf editor window (select Windows > Alf), if it isn't already open.
- In the Alf editor window, press Create. A menu will pop up with available options for creating Transition Behaviors.

- Select Effect Behavior.
Enter the Alf code for the Behavior and press Save to compile and save it.
To edit the Alf code for an effect Behavior
If you create an effect Behavior as an Opaque Behavior, then Alf code for it can also be entered or edited directly in the Body and Language property for it in the Specification window for the Transition. If you open the Edit Body and Language window, then the Alf code may be edited just as in the Alf editor window. However, instead of Save and Revert buttons, this window has OK and Cancel buttons, either of which will close it. If you press OK, then the text is saved, and, if it has no errors, compiled. If you press Cancel, the Alf text is not saved.

Editing Alf code for a Transition effect Behavior in an Opaque Behavior body