Leadtools.WinForms Send comments on this topic. | Back to Introduction - All Topics | Help Version 16.5.9.25
RasterImageListItemCollection Class
See Also  Members  
Leadtools.WinForms Namespace : RasterImageListItemCollection Class



Represents the collection of items in a RasterImageList control.

Object Model

Syntax

Visual Basic (Declaration) 
Public Class RasterImageListItemCollection 
   Inherits RasterCollection(Of RasterImageListItem)
Visual Basic (Usage)Copy Code
Dim instance As RasterImageListItemCollection
C# 
public class RasterImageListItemCollection : RasterCollection<RasterImageListItem> 
C++/CLI 
public ref class RasterImageListItemCollection : public RasterCollection<RasterImageListItem> 

Remarks

A RasterImageListItemCollection stores the items displayed in the RasterImageList control.

There are a number of ways to add items to the collection. The Add method adds a single item to the collection. To add a number of items to the collection, you create an array of items and pass it to the AddRange method. If you want to insert an item at a specific location in the collection, you can use the Insert method. To remove items, you can use either the Remove method or the RemoveAt method if you know where the item is located in the collection. The Clear method enables you to remove all items from the collection instead of using the Remove method to remove a single item at a time.

In addition to methods and properties for adding and removing items, the RasterImageListItemCollection also provides methods to find items in the collection. The Contains method enables you to determine whether an item is a member of the collection. Once you know that the item is located in the collection, you can use the IndexOf method to determine where the item is located in the collection.

NOTE: You cannot add an RasterImageListItem to more than one RasterImageList control at the same time. If you attempt to do this, an exception will be thrown.

Inheritance Hierarchy

System.Object
   Leadtools.RasterCollection<RasterImageListItem>
      Leadtools.WinForms.RasterImageListItemCollection

Requirements

Target Platforms: Microsoft .NET Framework 2.0, Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also