Spread for ASP.NET 11 Product Documentation
ListBoxCellType Constructor()
Example 


FarPoint.Web.Spread Assembly > FarPoint.Web.Spread Namespace > ListBoxCellType Class > ListBoxCellType Constructor : ListBoxCellType Constructor()
Creates a new list box cell.
Syntax
'Declaration
 
Public Function New()
'Usage
 
Dim instance As New ListBoxCellType()
public ListBoxCellType()
Example
This example creates a list box cell type, sets up an array of items for the list, sets the background and foreground color for the selected item and assigns the object to the first cell in the sheet.
FarPoint.Web.Spread.ListBoxCellType lbcell = new FarPoint.Web.Spread.ListBoxCellType();
lbcell.Items = new String[] {"Carbon", "Oxygen", "Hydrogen"};
lbcell.SelectedBackColor = Color.Yellow;
lbcell.SelectedForeColor = Color.DarkBlue;
FpSpread1.ActiveSheetView.Cells[0, 0].CellType = lbcell;
FpSpread1.ActiveSheetView.Rows[0].Height = 140;
Dim lbcell As New FarPoint.Web.Spread.ListBoxCellType()
lbcell.Items = New String() {"Carbon", "Oxygen", "Hydrogen"}
lbcell.SelectedBackColor = Color.Yellow
lbcell.SelectedForeColor = Color.DarkBlue
FpSpread1.ActiveSheetView.Cells(0, 0).CellType = lbcell
FpSpread1.ActiveSheetView.Rows(0).Height = 140
See Also

Reference

ListBoxCellType Class
ListBoxCellType Members
Overload List