LImageListControl::GetFirstVisible

Summary

Gets the index of the first visible item in the ImageList Control. This item is the one at the upper left corner of the control's view.

Syntax

#include "ltwrappr.h"

L_INT LImageListControl::GetFirstVisible ()

Returns

Value Meaning
>= 0 The zero-based index of the first visible item.
< 0 An error occurred. Refer to Return Codes.

Required DLLs and Libraries

Platforms

Win32, x64.

See Also

Functions

Topics

Example

L_INT LImageListControl__GetFirstVisibleExample(LImageListControl & ImageList, L_INT& nLastVisible) 
{ 
   L_INT nViewSize, nFirstVisible; 
   L_INT nColsOrRowsCount, nItemsCount; 
 
   nViewSize = ImageList.GetViewSize(); 
   nFirstVisible = ImageList.GetFirstVisible(); 
 
   if (ImageList.GetScrollStyle() == SCROLLSTYLE_VERTICAL) 
      nColsOrRowsCount = ImageList.GetColumnCount(); 
   else 
      nColsOrRowsCount = ImageList.GetRowCount(); 
 
   nLastVisible = nFirstVisible + (nViewSize * nColsOrRowsCount) - 1; 
 
   nItemsCount = ImageList.GetItemCount(); 
 
   if (nLastVisible > nItemsCount - 1) 
      nLastVisible = nItemsCount - 1; 
 
   return SUCCESS; 
} 
Help Version 23.0.2024.2.29
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2024 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Raster Imaging C++ Class Library Help

Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.