[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.Forms.ListBoxItem

ListBoxItem Class

Represents an item in a IListBox.

A ListBoxItem stores the display value used by a list box control. Create instances of this class and add them to Items to populate the available choices.

Inheritance
ListBoxItem
Namespace: GrapeCity.Documents.Excel.Forms
Assembly: DS.Documents.Excel.dll
Syntax
public class ListBoxItem : SelectorItem
Public Class ListBoxItem
    Inherits SelectorItem
Examples
IListBox listBox = worksheet.Controls.AddListBox(20, 20, 120, 80);
ListBoxItem item = new ListBoxItem("Item 1");
listBox.Items.Add(item);

Constructors

Name Description
ListBoxItem()

Creates an empty item.

Use this constructor to create a ListBoxItem without an initial value, and then assign its content through Value before adding it to Items.

ListBoxItem(string)

Creates a list box item with the specified value.

This constructor initializes the item by assigning value to Value.