Try OpenEdge Now
skip to main content
Programming Interfaces
Input/Output Processes : Colors and Fonts : Managing application environments : Using environment management statements
Using environment management statements
To replace the current environment with another application environment, ABL provides these statements:
*LOAD — Loads a previously defined application environment into ABL memory, or creates and loads an empty application environment to be defined. Generally, an application environment resides in the Registry or in an initialization file with a meaningful filename. You can load as many application environments as memory allows, but only one environment can be current at a time.
*USE — Makes a previously loaded environment available as the current environment. The new current environment has no effect on the default window or any previously created windows. The resources of the new current environment are available only for windows created after the new environment is made current.
*UNLOAD — Removes a loaded environment from ABL memory. Environments take up very little memory and generally do not have to be unloaded. However, if you are writing an application builder, this statement provides good housekeeping when you save and remove an application from memory. This allows you to remove all memory associated with a purged application.
Note that you must delete all windows created in an environment before you can unload that environment, whether or not it is the current environment. If the unloaded environment is the current environment, you must set a new current environment with the USE statement before continuing operation.
For more information on these statements, see their reference entries in OpenEdge Development: ABL Reference.