The script on this page creates a new StarOffice document and connects an event listener to it. When the document is closed then the XEventListener::disposing method is called on the listener object. How the listener is set up depends on the button being clicked.

The button will run JScript code that and adds an JScript event listener to the document. The listener is also implemented in JScript an is on this page..

The button runs JScript code that creates the ActiveX component EventListener.EvtListener that is written in C++ and housed in a dll. Then the event listener is added to the document.

The button runs VBScript code that creates the components EventListener.EvtListener and adds it to the document.

Runs VBScript code that creates VBasicEventListener.VBEventListener ActiveX component which was written with VB