Creating a Library Object

To Create a DESC object representing a library and load that library, use a declaration such as:

your_dll: DLL_32

where your_dll should be replaced by whatever name you have chosen to denote the library in your software, and execute a creation instruction of the form:

create your_dll.make ("your_lib_name")

where your_lib_name is the name of the file containing the library.

After this call has been executed, the boolean value your_dll.meaningful will be true if and only if the creation has been successful, that is to say, the given name did correspond to an available library, and it was possible to load it.

If your_dll.meaningful is false, you can have more details about the error by comparing the value of your_dll.error_code, an integer, to those of constant attributes defined in class DLL_32 and DLL_32_ROUTINE , supported by an auxiliary class SHARED_LIBRARY_CONSTANTS. As expressed by an invariant of class DLL_32, the value of meaningful is true if an only if error_code = 0.