Spread for ASP.NET 7.0 Product Documentation
CellType Property
See Also  Example Support Options
FarPoint.Web.Spread Assembly > FarPoint.Web.Spread Namespace > Cell Class : CellType Property


Glossary Item Box

Gets or sets the type of cell.

Syntax

Visual Basic (Declaration) 
Public Property CellType As ICellType
Visual Basic (Usage)Copy Code
Dim instance As Cell
Dim value As ICellType
 
instance.CellType = value
 
value = instance.CellType
C# 
public ICellType CellType {get; set;}

Property Value

ICellType object that contains the cell type for this cell

Remarks

The setting for this property can be overridden if a named style is assigned to the cell using the StyleName property, and that named style sets the cell type.

Example

This example creates a Cell object, sets in BackColor and ForeColor properties, defines it as a CheckBox cell type, and puts a border around it. When the user edits the cell and checks the CheckBox, the text of the cell changes.
C#Copy Code
FarPoint.Web.Spread.Cell mycell;
mycell = FpSpread1.Cells[0, 0];
mycell.BackColor = Color.RoyalBlue;
mycell.ForeColor = Color.White;
mycell.Border = new FarPoint.Web.Spread.Border(System.Web.UI.WebControls.BorderStyle.Double, Color.DarkBlue, 2);
mycell.CellType = new FarPoint.Web.Spread.CheckBoxCellType();
Visual BasicCopy Code
Dim mycell As FarPoint.Web.Spread.Cell
mycell = FpSpread1.Cells(0, 0)
mycell.BackColor = Color.RoyalBlue
mycell.ForeColor = Color.White
mycell.Border = New FarPoint.Web.Spread.Border(System.Web.UI.WebControls.BorderStyle.Double, Color.DarkBlue, 2)
mycell.CellType = New FarPoint.Web.Spread.CheckBoxCellType()

Requirements

Target Platforms: Windows 7, Windows 8, Windows Vista, Windows Server 2000, Windows 2000 Professional, Windows XP Professional, Windows NT 4.0 Workstation, SP6, Windows NT 4.0 Server, SP6

See Also

© 2002-2014 ComponentOne, a division of GrapeCity. All Rights Reserved.