共用方式為


ListBoxItem 類別

定義

警告

Microsoft.VisualBasic.Compatibility.* classes are obsolete and supported within 32 bit processes only. http://go.microsoft.com/fwlink/?linkid=160862

代表應用程式中從 Visual Basic 6.0 升級而來的 or ComboBox 控制項ListBox項目。

public ref class ListBoxItem
public class ListBoxItem
[System.Obsolete("Microsoft.VisualBasic.Compatibility.* classes are obsolete and supported within 32 bit processes only. http://go.microsoft.com/fwlink/?linkid=160862")]
public class ListBoxItem
type ListBoxItem = class
[<System.Obsolete("Microsoft.VisualBasic.Compatibility.* classes are obsolete and supported within 32 bit processes only. http://go.microsoft.com/fwlink/?linkid=160862")>]
type ListBoxItem = class
Public Class ListBoxItem
繼承
ListBoxItem
屬性

備註

在 Visual Basic 6.0 中,ListBoxComboBox 控制項使用一個屬性來儲存清單項目,另一個ItemData屬性則可List選擇性地儲存Integer與每個清單項目相關的一個。 在 Visual Basic 中, ListBox and ComboBox 控制項使用 該 Items 屬性來儲存清單項目,但該 ItemData 屬性已不再支援。

當 Visual Basic 6.0 應用程式升級至 Visual Basic 時,升級工具會為 or ComboBox 控制項中的ListBox每個項目建立ListBoxItem一個類別。 SetItemData接著可以使用 and GetItemData 函式來啟用任何參考該ItemData屬性的程式碼。

備註

命名空間中的 Microsoft.VisualBasic.Compatibility.VB6 函式與物件提供給從 Visual Basic 6.0 升級到 Visual Basic 2008 的工具使用。 在大多數情況下,這些函式和物件會重複你在 .NET Framework 其他命名空間中能找到的功能。 只有當 Visual Basic 6.0 的程式碼模型與 .NET Framework 實作有顯著差異時,才需要使用。

建構函式

名稱 Description
ListBoxItem(String, Int32)
已淘汰.

初始化該 ListBoxItem 類別的實例。

ListBoxItem(String)
已淘汰.

初始化該 ListBoxItem 類別的實例。

欄位

名稱 Description
ItemData
已淘汰.

ItemData 項目值儲存在從 Visual Basic 6.0 升級而來的應用程式中 a ListBoxComboBox 控制項中。

ItemString
已淘汰.

List 項目值儲存在從 Visual Basic 6.0 升級而來的應用程式中 a ListBoxComboBox 控制項中。

方法

名稱 Description
Equals(Object)
已淘汰.

判斷指定的物件是否等於目前的物件。

(繼承來源 Object)
GetHashCode()
已淘汰.

做為預設哈希函式。

(繼承來源 Object)
GetType()
已淘汰.

取得目前實例的 Type

(繼承來源 Object)
MemberwiseClone()
已淘汰.

建立目前 Object的淺層複本。

(繼承來源 Object)
ToString()
已淘汰.

ListBoxItem 轉換成 String

適用於