WIDGET POOL

If WIDGETs are created in the code, always create a WIDGET POOL using the “CREATE WIDGET POOL” statement or the USE-WIDGET-POOL option of the CLASS statement.

And then use the "DELETE OBJECT" statement with "IF VALID-HANDLE" or "IF VALID-OBJECT" in the FINALLY block (alternatively use the Consultingwerk.Util.GarbageCollectorHelper).

Exception are those widget references that are returned to the outside from factory methods.