Spread for ASP.NET 10 Product Documentation
Setting the Background Color of the Sheet

You can customize the background color of the data area of the sheet. The sheet background color is displayed as the cell background color, unless you set specific cell colors (as explained in Customizing the Colors of a Cell). It is also the color in the rest of the sheet where cells are not displayed (empty area), as shown in the following figure, where the background color is set to light yellow.

The background color for the sheet can be set either with the BackColor property of the sheet (SheetView class) or the BackColor property of the SheetSkin class and the skin applied to the sheet.

Using the Properties Window

  1. At design time, in the Properties window, select the Sheets property for the FpSpread component.
  2. Click the button to display the SheetView Collection Editor.
  3. In the Members list, select the sheet for which to set the background color.
  4. Select the BackColor property in the property list, and then click the drop-down button to display the color picker.
  5. Select a color in the color picker.
  6. Click OK to close the editor.

Using a Shortcut

Set the BackColor property of the FpSpread component Sheets shortcut.

Example

This example code sets the background color of the first sheet to light yellow.

C#
Copy Code
// Set the first sheet's background color to light yellow.
FpSpread1.Sheets[0].BackColor = Color.LightYellow; 
VB
Copy Code
' Set the first sheet's background color to light yellow.
FpSpread1.Sheets(0).BackColor = Color.LightYellow 

Using the Spread Designer

  1. From the sheets displayed at the bottom, select the sheet for which you want to set the background color.
  2. Select the BackColor property in the property list.
  3. Click the drop-down arrow to display the color picker.
  4. Select a color from the color picker.
  5. Click Apply and Exit to close the Spread Designer.

 

 


Copyright © GrapeCity, inc. All rights reserved.

Support Options | Documentation Feedback