GrapeCity Spread Silverlight CTP, Part 6 - Cell Span
Spread CTP - Script 6: Cell Span
If you are interested in downloading the Spread CTP, please email labs@grapecity.com .
This is the 6th in a series of Spread CTP Blogs and is a continuation of:
Part 1 : Create an app from scratch
Part 2 : AutoFit
Part 3 : Borders and Grid Lines
Part 4 : Cell Format
Part 5 : Cell Overflow
You can create a cell span in the cell, row header, or column header area. You can also remove or clear cell spans.
The entire span is treated as an active cell when using the Tab key to move the active cell to the spanned cell. The active cell outline includes the entire span.
The following image displays a span in the cell and header areas:
Using Code
GrapeCity.Windows.SpreadSheet.Data.CellRange r;
r = new GrapeCity.Windows.SpreadSheet.Data.CellRange(0, 0, 3, 3);
gcSpreadSheet1.Sheets[0].AddSpanCell(r, GrapeCity.Windows.SpreadSheet.Data.SheetArea.Cells);
gcSpreadSheet1.Sheets[0].RowHeader.ColumnCount = 2;
gcSpreadSheet1.Sheets[0].ColumnHeader.RowCount = 2;
GrapeCity.Windows.SpreadSheet.Data.CellRange r2;
r2 = new GrapeCity.Windows.SpreadSheet.Data.CellRange(0, 0, 2, 2);
gcSpreadSheet1.Sheets[0].AddSpanCell(r2, GrapeCity.Windows.SpreadSheet.Data.SheetArea.RowHeader);
gcSpreadSheet1.Invalidate();
VB.NET
Dim r As GrapeCity.Windows.SpreadSheet.Data.CellRange
r = New GrapeCity.Windows.SpreadSheet.Data.CellRange(0, 0, 3, 3)
GcSpreadSheet1.Sheets(0).AddSpanCell(r, GrapeCity.Windows.SpreadSheet.Data.SheetArea.Cells)
GcSpreadSheet1.Sheets(0).RowHeader.ColumnCount = 2
GcSpreadSheet1.Sheets(0).ColumnHeader.RowCount = 2
Dim r2 As GrapeCity.Windows.SpreadSheet.Data.CellRange
r2 = New GrapeCity.Windows.SpreadSheet.Data.CellRange(0, 0, 2, 2)
GcSpreadSheet1.Sheets(0).AddSpanCell(r2, GrapeCity.Windows.SpreadSheet.Data.SheetArea.RowHeader)
GcSpreadSheet1.Invalidate()
Technorati Tags: Spread,Excel,Silverlight,CTP,labs@grapecity.com,visual studio,AutoFit,borders and Grid lines,cell format,cell overflow,cell span
tweetmeme_url = 'http://www.clubfarpoint.com/Forums/blogs/russells\_blog/archive/2012/03/27/grapecity-spread-silverlight-ctp-part-6-cell-span.aspx'; tweetmeme_source = '@russcamtv'; tweetmeme_hashtags = '#appdev';