Spread Windows Forms 6.0 Product Documentation
DataAreaDefault Field
See Also  Example Support Options
FarPoint.Win.Spread Assembly > FarPoint.Win.Spread Namespace > DefaultStyleCollection Class : DataAreaDefault Field


Glossary Item Box

Represents the default style for data area cells.

Syntax

Visual Basic (Declaration) 
Public Shared ReadOnly DataAreaDefault As NamedStyle
Visual Basic (Usage)Copy Code
Dim value As NamedStyle
 
value = DefaultStyleCollection.DataAreaDefault
C# 
public static readonly NamedStyle DataAreaDefault

Field Value

NamedStyle object containing the style

Remarks

Note that if you set properties for DefaultStyleCollection.DataAreaDefault or DefaultStyleCollection.HeaderDefault, they affect all Spread controls on the system because these objects are static, and thus shared by all Spread controls on all Windows Forms in all applications. If you need to set it only for a particular sheet, you should set SheetView.DefaultStyle (for cells in the data area) or SheetView.ColumnHeader.DefaultStyle or SheetView.RowHeader.DefaultStyle properties (for cells in the headers) so that only the sheet is affected.

Example

This example checks to see if the DefaultStyleCollection contains the default style for cells in the data area.
C#Copy Code
FarPoint.Win.Spread.DefaultStyleCollection dsc = new FarPoint.Win.Spread.DefaultStyleCollection();
bool b, b1;
b = dsc.Contains(FarPoint.Win.Spread.DefaultStyleCollection.DataAreaDefault);
b1 = dsc.Contains(FarPoint.Win.Spread.DefaultStyleCollection.HeaderDefault);
listBox1.Items.Add(b.ToString());
listBox1.Items.Add(b1.ToString());
Visual BasicCopy Code
Dim dsc As New FarPoint.Win.Spread.DefaultStyleCollection()
Dim b, b1 As Boolean
b = dsc.Contains(dsc.DataAreaDefault)
b1 = dsc.Contains(dsc.HeaderDefault)
ListBox1.Items.Add(b.ToString())
ListBox1.Items.Add(b1.ToString())

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

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