L_DispContainerSetCellBitmapList

#include "ltivw.h"

L_LTIVW_API L_INT L_DispContainerSetCellBitmapList(hCon, nCellIndex, hBitmapList, bCleanImage, uFlags)

HDISPCONTAINER hCon;

/* handle to the container */

L_INT nCellIndex;

/* index of the cell */

HBITMAPLIST hBitmapList;

/* handle to the list of bitmaps */

L_BOOL bCleanImage;

/* free the bitmap list flag */

L_UINT uFlags;

/* reserved for future use */

Attaches a bitmap list to the cell at the specified index.

Parameter

Description

hCon

Handle to the container.

nCellIndex

A zero-based index of the cell to which to attach the bitmap list specified in hBitmapList.

hBitmapList

Handle to the list of bitmaps, which will be attached to the cell at the index specified in nCellIndex. Pass NULL to remove the current bitmap list.

 

Removing the current bitmap list will not free the attached image(s). The value in the bCleanImage parameter determines whether the image(s) associated with the removed bitmap list are also freed.

bCleanImage

Flag that specifies whether to free the bitmap list that was previously attached to the cell. Possible values are:

 

Value

Meaning

 

TRUE

Free the bitmap list that was previously attached to the cell.

 

FALSE

Do not free the bitmap list that was previously attached to the cell.

uFlags

Reserved for future use. Pass 0.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

It is best not to modify an existing bitmap list attached to a specific cell. However, if it is necessary to modify an attached bitmap list, follow the steps below:

1.

Get the bitmap list using the function L_DispContainerGetCellBitmapList.

2.

Call L_DispContainerSetCellBitmapList with hBitmapList set to NULL and bCleanImage set to FALSE.

3.

Modify the bitmap list as needed.

4.

Reattach the bitmap list using L_DispContainerSetCellBitmapList.

If the cell already has a bitmap list and you call this function with hBitmapList set to another valid list of bitmaps and bCleanImage set to TRUE, this function frees the current attached list and attaches the new list to the cell.

If the cell already has a bitmap list and you call this function with hBitmapList set to another valid list of bitmaps and bCleanImage set to FALSE, this function will just overwrite the current list of bitmap with the new list of bitmaps. And the current list will just take up memory until the application ends.

Required DLLs and Libraries

LTIVW

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application.

See Also

Functions:

L_DispContainerCreate, L_DispContainerRemoveCell, L_DispContainerInsertCell, L_DispContainerGetCellCount, L_DispContainerGetCellWindowHandle, L_DispContainerSetCellTag, L_DispContainerSetCellProperties, L_DispContainerGetCellProperties, L_DispContainerGetCellPosition, L_DispContainerRepositionCell, L_DispContainerGetCellBitmapList, L_DispContainerGetCellBounds, L_DispContainerFreezeCell, L_DispContainerSelectCell, L_DispContainerIsCellSelected, L_DispContainerIsCellFrozen

Topics:

Image Viewer Cells

 

Image Viewer Functions: Image Viewer Cells

Example

For an example, refer to L_DispContainerCreate.