Background for Skyrim SE
Member of the Form script
eventOnMenuClose(stringmenuName)

Description

Wiki Description

Listens for closing of UI previously registered via Form.RegisterForMenu(...). (This function requires SKSE)


Caveats

CK Wiki - Notes

  • If multiple menus are registered, you'll want to differentiate in the corresponding event body as shown in the example. If only one menu is to be registered, no such differentiation is necessary.

Parameters

stringmenuName

CK Wiki Description

The UI listened for.


Examples

Event OnInit()
    RegisterForMenu("ContainerMenu")
EndEvent
 
Event OnMenuClose(String MenuName)
    Debug.Trace("A registered menu has closed.")
    If MenuName == "ContainerMenu"
        Debug.Trace("ContainerMenu has been registered and has closed.")
    EndIf
EndEvent

Auto-Generated Example

Scriptname MyCoolScript extends Form

event OnMenuClose(string menuName)
    Debug.trace("Event received - OnMenuClose: menuName = " + menuName)
endEvent

Related Pages


Additional References

View this event’s page on the Skyrim Creation Kit Wiki

Some data provided by the Skyrim Creation Kit Wiki. Licensed under the Creative Commons Attribution-ShareAlike license.