Spread ASP.NET 6.0 Product Documentation
Setting a General Cell
Send Feedback
Spread ASP.NET 6.0 Product Documentation > Developer's Guide > Customizing with Cell Types > Working with Editable Cell Types > Setting a General Cell

Glossary Item Box

Users can type text or numbers in a general cell type. The general cell type can also be used as a base from which to inherit generic cell type information.

The general cell will format the values the user types into strings, numbers, or dates. The text cell formats user typed values as strings.

For details on the properties and methods for this cell type, refer to the GeneralCellType class.

Return to the overview of editable cell types at Working with Editable Cell Types.

Using Code

  1. Define the general cell type by creating an instance of the GeneralCellType class.
  2. Assign the general cell type to a cell.

Example

This example sets a cell to be a general cell.

C# Copy Code
FarPoint.Web.Spread.GeneralCellType gencell =     new FarPoint.Web.Spread.GeneralCellType(); 
FpSpread1.ActiveSheetView.Cells[1, 1].CellType = gencell;
VB Copy Code
Dim gencell As New FarPoint.Web.Spread.GeneralCellType()
FpSpread1.ActiveSheetView.Cells(1, 1).CellType = gencell

Using the Spread Designer

  1. In the work area, select the cell or cells for which you want to set the cell type.
  2. Select the Home menu.
  3. Select the SetCellType icon under the CellType section.
  4. Select the cell type and any other cell properties.
  5. Select OK to close the dialog.
  6. Click Apply and Exit to close the Spread Designer.
© 2002-2012 GrapeCity, Inc. All Rights Reserved.