This documentation is archived and is not being maintained.

ListBox.CreateItemCollection Method

Creates a new instance of the item collection.

[Visual Basic]
Protected Overridable Function CreateItemCollection() As _
   ObjectCollection
[C#]
protected virtual ObjectCollection CreateItemCollection();
[C++]
protected: virtual ObjectCollection* CreateItemCollection();
[JScript]
protected function CreateItemCollection() : ObjectCollection;

Return Value

A ListBox.ObjectCollection that represents the new item collection.

Remarks

Notes to Inheritors:  You can override this in your derived classes to provide a different collection to store your items.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

ListBox Class | ListBox Members | System.Windows.Forms Namespace | ListBox.ObjectCollection

Show: