BBjImageManager::loadImageFromImageList

Description

In BBj 5.0 and higher, this method loads a BBjImage object from an image list.

Syntax

Return Value

Method

BBjImage

loadImageFromImageList(int id, int index)

Parameters

Variable

Description

id

Image list ID.

index

Zero-based index of the image to be loaded.

Return Value

Returns the image as a BBjImage object.

Remarks

None.

Example

rem 'Load a BBjImage from an imagelist

rem 'Obtain the instance of the BBjAPI object
let myAPI! = BBjAPI()

rem 'Open the SysGui device
SYSGUI = UNT
OPEN (SYSGUI)"X0"

rem 'Obtain the instance of the BBjSysGui object
let mySysGui! = myAPI!.getSysGui()

rem 'Obtain the instance of the Image Manager object
let myImageManager! = mySysGui!.getImageManager()

rem 'Get the image from a file
let myImage! = myImageManager!.loadImageFromFile("updown.bmp")

rem 'Create the imagelist
let id = 1
let width = 8
mySysGui!.addImageList(id,width,myImage!)

rem 'Obtain an instance of the BBjImageManager object
myImageManager! = mySysGui!.getImageManager()

rem 'Load an image from a file
myImage! = myImageManager!.loadImageFromImageList(id,0)

See Also

BBjAPI

BBjSysGui

BBjImageManager

BBjImage

See the BBj Object Diagram for an illustration of the relationship between BBj Objects.