If users can install your application as either Administrator or personal instances, your application might need logic to alter where it reads and writes registry information based, on the type of installation. To enable this, the SESSION system handle has a new attribute, WC-ADMIN-APP. The following code snippet is an example of such logic:
DEFINE VARIABLE cAppKey AS CHARACTER NO-UNDO.
IF SESSION:WC-ADMIN-APP THEN
cAppKey = "HKEY_LOCAL_MACHINE".
ELSE
cAppKey = "HKEY_CURRENT_USER".
LOAD "MyEnvironment" BASE-KEY cAppKey.
For more information on this attribute, see OpenEdge Development: ABL Reference.