Spread for ASP.NET 11 Product Documentation
GetColumnMerge Method
Example 


FarPoint.Web.Spread Assembly > FarPoint.Web.Spread Namespace > SheetView Class : GetColumnMerge Method
Column index
Gets whether or how cells in a column on this sheet that have the same content are joined in a single cell across multiple rows.
Syntax
'Declaration
 
Public Function GetColumnMerge( _
   ByVal column As Integer _
) As MergePolicy
'Usage
 
Dim instance As SheetView
Dim column As Integer
Dim value As MergePolicy
 
value = instance.GetColumnMerge(column)
public MergePolicy GetColumnMerge( 
   int column
)

Parameters

column
Column index

Return Value

MergePolicy setting that specifies if and how cells in this column are automatically merged
Remarks
Cells with the same content are automatically merged if the merge policy is set to allow it. To span cell manually refer to the AddSpanCell method, etc.
Example
This example returns the merge policy for the model.
FpSpread1.ActiveSheetView.Cells[0, 2, 2, 2].Text = "Test";
FpSpread1.ActiveSheetView.SetColumnMerge(2, FarPoint.Web.Spread.Model.MergePolicy.Always); 

FarPoint.Web.Spread.Model.MergePolicy mp;
mp = FpSpread1.ActiveSheetView.GetColumnMerge(2);
Response.Write(mp.ToString());
FpSpread1.ActiveSheetView.Cells(0, 2, 2, 2).Text = "Test"
FpSpread1.ActiveSheetView.SetColumnMerge(2, FarPoint.Web.Spread.Model.MergePolicy.Always)

Dim mp As FarPoint.Web.Spread.Model.MergePolicy
mp = FpSpread1.ActiveSheetView.GetColumnMerge(2)
Response.Write(mp.ToString())
See Also

Reference

SheetView Class
SheetView Members
GetRowMerge Method
SetColumnMerge Method

User-Task Documentation

Merging Cells Automatically