WBITMAP-LOAD (op-code 3)

This operation loads bitmapped images from disk into memory so that they can be displayed with bitmapped buttons.

Note: You may not use remote name notation with this operation.

This op-code takes three additional parameters. They are, in order:

name A literal or data item containing the name of the file to load. The length of the name (including path) should not exceed 90 characters. This limit may vary on different operating systems.
bitmap-handle    A PIC S9(9) COMP-4 data item that stores a handle to the bitmapped image loaded into memory.
flags A numeric parameter that contains loading options. This parameter can be omitted.

Currently the only option is WBITMAP-NO-DOWNLOAD. This option is intended for programs that are deployed with the ACUCOBOL-GT Thin Client. When the option is set, the server does not download the specified bitmap to the client. The flag indicates to the server that the bitmap is already in the client's cache directory. To properly use the option, the program must keep track of whether the bitmap is already in the client's cache.

If the operation is successful, bitmap-handle holds a positive value. If bitmap-handle is 0 or negative, an error occurred.

If you have bitmapped images in more than one file, you need to load each file before using the images they contain. Be sure to store separate handles for each file loaded.

When you are done with an image and have destroyed all the buttons that reference that image, you can remove it from memory with the WBITMAP-DESTROY operation. Do not destroy an image that is referenced by an active control or print job, because the results are unpredictable.