Spread Windows Forms 12.0 Product Documentation
HorizontalAlignment Property (AlternatingRow)
Example 


FarPoint.Win.Spread Assembly > FarPoint.Win.Spread Namespace > AlternatingRow Class : HorizontalAlignment Property
Gets or sets the horizontal alignment for text in the cells in this alternating row.
Syntax
'Declaration
 
Public Property HorizontalAlignment As CellHorizontalAlignment
'Usage
 
Dim instance As AlternatingRow
Dim value As CellHorizontalAlignment
 
instance.HorizontalAlignment = value
 
value = instance.HorizontalAlignment
public CellHorizontalAlignment HorizontalAlignment {get; set;}

Property Value

CellHorizontalAlignment object containing the horizontal alignment for cell contents
Remarks

To create alternating rows, first set the AlternatingRows.Count property to specify the number of alternating row patterns, then set the properties for each pattern.

Example
This example specifies the text alignment for the alternating row.
FarPoint.Win.Spread.AlternatingRow altrow;
altrow = fpSpread1.ActiveSheet.AlternatingRows[0];
altrow.HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Right;
altrow.VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Top;
fpSpread1.ActiveSheet.Rows[0].Height = 80;
fpSpread1.ActiveSheet.Columns[0].Width = 120;
fpSpread1.ActiveSheet.Cells[0, 0].Text = "Alignment";
Dim altrow As FarPoint.Win.Spread.AlternatingRow
altrow = fpSpread1.ActiveSheet.AlternatingRows(0)
altrow.HorizontalAlignment = FarPoint.Win.Spread.CellHorizontalAlignment.Right
altrow.VerticalAlignment = FarPoint.Win.Spread.CellVerticalAlignment.Top
fpSpread1.ActiveSheet.Rows(0).Height = 80
fpSpread1.ActiveSheet.Columns(0).Width = 120
fpSpread1.ActiveSheet.Cells(0, 0).Text = "Alignment"
See Also

Reference

AlternatingRow Class
AlternatingRow Members
CellHorizontalAlignment Enumeration
Count Property

User-Task Documentation

Creating Alternating Rows