Method ‘FB_Exit’

FB_Exit is a special method for a function block. It is called before the code of the function block is removed from the controller.

For more information about using FB_Exit, FB_Init, and FB_Reinit in different operational conditions, definitely refer also to the help pages for FB_Init and FB_Reinit.

Since there is no implicit declaration you must explicitly declare FB_Exit.

If FB_Exit is called explicitly, then the return value can be evaluated. However, if this function is called implicitly, then the respective return value is not evaluated.

Interface of the FB_Exit method: There is only one required parameter:

METHOD fb_exit : BOOL
VAR_INPUT
 bInCopyCode : BOOL; //  TRUE: The exit method is called in order to leave the instance, which will be copied afterwards (Online Change).
END_VAR

See also