Support.SetItemData Method

Sets the ItemData property for a ListBoxItem.

Namespace: Microsoft.VisualBasic.Compatibility.VB6
Assembly: Microsoft.VisualBasic.Compatibility (in microsoft.visualbasic.compatibility.dll)

public static void SetItemData (
	Control Control,
	int Index,
	int ItemData
)
public static void SetItemData (
	Control Control, 
	int Index, 
	int ItemData
)
public static function SetItemData (
	Control : Control, 
	Index : int, 
	ItemData : int
)
Not applicable.

Parameters

Control

A ListBoxListBox or ComboBox control.

Index

The Index of the ListBoxItem.

ItemData

An Integer to assign to the ItemData property.

In Visual Basic 6.0, the ItemData property for a ListBox or ComboBox control could be set at design time in the Properties window to associate an Integer with a ListBox or ComboBox item. In Visual Basic Code Name "Orcas", the ItemData property no longer exists; the GetItemData and SetItemData methods can be used to emulate the behavior of ItemData.

Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0

Community Additions

ADD
Show: