L_ILM_GETPAGECOUNT - Raster Imaging C API Help

L_ILM_GETPAGECOUNT

Send this message to get the number of pages of items in the ImageList Control.

Parameter

Description

wParam

Ignored, use 0.

lParam

Ignored, use 0.

Returns

>=0

The number of pages

< 0

An error occurred. Refer to Return Codes.

Comments

This message will return the total number of pages of items in the ImageList Control. Pages are calculated using the total number of rows or columns (depending on the scroll style) and the total number of rows or columns (depending on the scroll style) that are completely visible in the ImageList Control's client area.

The associated macro is:

L_ImgListGetPageCount(hWnd)

For a complete list of available macros, refer to the Ltlst.h file.

See Also

Elements:

L_ILM_GETPAGE, L_ILM_GETITEMCOUNT, L_ILM_GETROWCOUNT, L_ILM_GETCOLCOUNT, L_ILM_GETSELCOUNT, L_ILM_GETSCROLLSTYLE

Topics:

Using the ImageList Control

 

Image List Control Messages

Example

L_INT ILM_GETPAGECOUNTExample(HWND hCtrl) 
{ 
   L_INT32 lCount; 
   L_INT32 lPage; 
   L_TCHAR buf[200]; 
   if(IsWindow(hCtrl)) 
   { 
      /* get current page count */ 
      lCount = (L_INT32)SendMessage(hCtrl, L_ILM_GETPAGECOUNT, 0, 0L); 
      /* get current page */ 
      lPage = (L_INT32)SendMessage(hCtrl, L_ILM_GETPAGE, 0, 0L); 
      wsprintf(buf, TEXT("Page: %ld of %ld Pages!"), lPage, lCount); 
      MessageBox(hCtrl, buf, TEXT("Page Count"), MB_OK); 
 
      return SUCCESS; 
   } 
   else 
      return ERROR_INVALID_PARAMETER; 
} 
Help Version 20.0.2018.7.30
Products | Support | Contact Us | Copyright Notices
© 1991-2018 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Raster Imaging C API Help