* :--------------------------------------- * ------------------------: Extended Registry functions * : * : See the documentation for details. * :--------------------------------------- * * The Extended registry functions allow you to (optionally) * supply the complete high-order node of a registry key, which * allows you to read or write data anywhere in the Registry. * ---------------------------------------------------------------- * * Client/Server Notes: * * The extended functions allow you to select whether you access * the registry on the SERVER or on the CLIENT. (The original * registry functions always access the registry of the SERVER.) * * Note: Unless otherwise specified, the extended function will * access the registry of the CLIENT. If you want to access the * registry on the SERVER: * * SET WIN32API-EXECUTE-API-ON-SERVER TO TRUE * ---------------------------------------------------------------- * * If you select EX-REG-HKEY-DEFAULT, GUI ScreenIO will * automatically store your application data in the correct * location in the Registry, complying with Microsoft Windows * standards. The high-order node of the registry key uses the * Company and Application values supplied in your MAIN panel, * and the value you supply in SUBKEY is appended to it. * * The complete registry key generated by GUI ScreenIO is: * * HKEY_CURRENT_USER\Software\Company\Application\Subkey * * Your data is stored beneath your key in name/data pairs. You * may have many VALUENAME=DATA pairs stored beneath a single key. * * Note: 1. You must provide the company name and the name of your * application when you open your main/container panel. * ---------------------------------------------------------------- * * The functions are all similar. Here's how to find out what * type of processor is installed on the target machine: * * COPY WIN32API. * COPY REGISTRY. * COPY REG-EX. * . * . * * ------------------------: Select the major node. * * SET EX-REG-HKEY-LOCAL-MACHINE TO TRUE. * * ------------------------: Set the subkey value. * * STRING 'HARDWARE\' * 'DESCRIPTION\' * 'System\' * 'CentralProcessor\' * '0' * DELIMITED SIZE INTO REGISTRY-SUBKEY. * * ------------------------: Specify the value name. * * MOVE 'ProcessorNameString' TO REGISTRY-VALUENAME. * * ------------------------: Call the API to get the value. * * SET FUNC-EX-REGISTRY-GET TO TRUE. * CALL 'GSWINAPI' USING WIN32API-PARMS * REGISTRY-PARMS * EXTENDED-REGISTRY-PARMS * WIN32API-C * WIN32API-D * WIN32API-E * WIN32API-F. * * ------------------------: If function failed, * : display a textual error message. * * IF WIN32API-FAILED * MOVE WIN32API-ERROR-TEXT TO my-error-message * do whatever to display my-error-message * ELSE * MOVE REGISTRY-DATA TO ... * * ---------------------------------------------------------------- * 01 EXTENDED-REGISTRY-PARMS. * : Predefined major registry key. 05 EX-REGISTRY-MAJOR-KEY PIC X VALUE LOW-VALUE. 88 EX-REG-HKEY-DEFAULT VALUE LOW-VALUE. 88 EX-REG-HKEY-CURRENT-USER VALUE '1'. 88 EX-REG-HKEY-CLASSES-ROOT VALUE '2'. 88 EX-REG-HKEY-LOCAL-MACHINE VALUE '3'. 88 EX-REG-HKEY-USERS VALUE '4'. 88 EX-REG-HKEY-CURRENT-CONFIG VALUE '5'. * : Reserved for future use 05 FILLER PIC X(1023) VALUE LOW-VALUE.