Where information about your object is stored

Information about a registered object is stored in the registry in three or four places. There is a section for a:

All this cross-referencing ensures that an object’s information can be found no matter what the program starts with.

Keys and their subtrees

The PowerBuilder.Application functions update the tree HKEY_CLASSES_ROOT. The other keys in the registry reflect this information for a particular context.

Subkeys

Information for each entry is stored in subkeys, which are a level below the entry subkey. Some subkeys have values, such as a file name. Others have meaning just because they are there, such as NotInsertable.

Each entry and its associated subkeys is described below.

ProgID

The list of registered ProgIDs appears in the registry under this key:

My Computer\HKEY_LOCAL_MACHINE\SOFTWARE\CLASSES

Both version-dependent and version-independent ProgIDs appear. The ProgID is a cross-reference to the object’s CLSID.

Table 20-2: ProgID subkeys

Subkey

Value

\CLASSES\ProgID

Description of object

\CLASSES\ProgID\CLSID

The object’s CLSID

\CLASSES\ProgID\CurVer (for the version-independent entry only)

The version-dependent ProgID

\CLASSES\ProgID\NotInsertable

Empty string

CLSID

Under the CLASSES key is a subkey CLSID that lists all the registered CLSIDs. Each CLSID records all the information about the registered object:

My Computer\HKEY_LOCAL_MACHINE\SOFTWARE\CLASSES\CLSID
Table 20-3: CLSID subkey contents

Subkey

Value

\CLASSES\CLSID\{guid}

The GUID for the object.

\CLASSES\CLSID\{guid}\InProcServer32

The path and file name for the PowerBuilder runtime DLL.

\CLASSES\CLSID\{guid}\NotInsertable

""

\CLASSES\CLSID\{guid}\PowerBuilder

Not set. Subkeys store information about the object’s environment (see below).

\CLASSES\CLSID\{guid}\Programmable

""

\CLASSES\CLSID\{guid}\ProgID

The ProgID you specified with the current version number.

\CLASSES\CLSID\{guid}\TypeLib

The CLSID for the type library.

\CLASSES\CLSID\{guid}\ VersionIndependentProgID

The ProgID you specified without a version number.

Table 20-4: PowerBuilder subkey contents

PowerBuilder subkey under \CLASSES\CLSID

Value

{guid}\PowerBuilder\BinaryType

The type of code in the library, either compiled machine code (MCODE) or Pcode

{guid}\PowerBuilder\LibraryList

The name of the library that contains the object

{guid}\PowerBuilder\ClassName

The object’s name in the library

TypeLib

Under the CLASSES key is another subkey for TypeLib.

My Computer\HKEY_LOCAL_MACHINE\SOFTWARE\CLASSES
   TypeLib
Table 20-5: TypeLib subkey contents

Subkey

Value

\CLASSES\TypeLib\{guid}

The GUID for the type library.

\CLASSES\TypeLib\{guid}\VersionNum

The version number of the type library.

A tree of subkeys is below the version number, allowing entries for type libraries in several languages.

VersionNum\LanguageID\Win32 specifies the path and name of type library file for 32-bit Windows operating systems.

\CLASSES\TypeLib\{guid}\FLAGS

0

\CLASSES\TypeLib\{guid}\HELPDIR

The directory where a Help file is located.