Visual Basic (Declaration) | |
---|---|
Public Property DefaultStyleName As String |
Visual Basic (Usage) | Copy Code |
---|---|
Dim instance As RowHeader Dim value As String instance.DefaultStyleName = value value = instance.DefaultStyleName |
C# | |
---|---|
public string DefaultStyleName {get; set;} |
Property Value
String containing the name of the style for this column headerException | Description |
---|---|
System.ArgumentException | Specified style (NamedStyle object) could not be found in the collection |
This example creates a row header and a style for the spreadsheet. The background color in the style is set to yellow, and is then applied to the row header so all the row headers then have a yellow background.
C# | Copy Code |
---|---|
FarPoint.Web.Spread.RowHeader rhdr; FarPoint.Web.Spread.NamedStyle mnstyle = new FarPoint.Web.Spread.NamedStyle(); mnstyle.Name = "fpstyle"; mnstyle.BackColor = Color.Yellow; FpSpread1.NamedStyles.Add(mnstyle); rhdr = FpSpread1.ActiveSheetView.RowHeader; rhdr.DefaultStyleName = mnstyle.Name; |
Visual Basic | Copy Code |
---|---|
Dim rhdr As FarPoint.Web.Spread.RowHeader Dim mnstyle As New FarPoint.Web.Spread.NamedStyle() mnstyle.Name = "fpstyle" mnstyle.BackColor = Color.Yellow FpSpread1.NamedStyles.Add(mnstyle) rhdr = FpSpread1.ActiveSheetView.RowHeader rhdr.DefaultStyleName = mnstyle.Name |
Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family
Reference
RowHeader ClassRowHeader Members
DefaultStyle Property