GrapeCity.Xaml.SpreadSheet.Data
AddColumns(Int32,Int32) Method
Example 


GrapeCity.Xaml.SpreadSheet.Data Namespace > Worksheet Class > AddColumns Method : AddColumns(Int32,Int32) Method
Column index at which to add the new columns.
The number of columns to add.
Adds the column or columns to the data model at the specified index.
Syntax
'Declaration
 
Public Overloads Sub AddColumns( _
   ByVal column As Integer, _
   ByVal count As Integer _
) 
'Usage
 
Dim instance As Worksheet
Dim column As Integer
Dim count As Integer
 
instance.AddColumns(column, count)
public void AddColumns( 
   int column,
   int count
)

Parameters

column
Column index at which to add the new columns.
count
The number of columns to add.
Example
This example uses the AddColumns method.
gcSpreadSheet1.Sheets[0].SetValue(0, 0, "value");
gcSpreadSheet1.Sheets[0].AddRows(0, 2);
gcSpreadSheet1.Sheets[0].AddColumns(0, 2);
gcSpreadSheet1.Sheets[0].SetRowHeight(0, GrapeCity.Xaml.SpreadSheet.Data.SheetArea.Cells, 50d);
gcSpreadSheet1.Sheets[0].SetColumnWidth(0, GrapeCity.Xaml.SpreadSheet.Data.SheetArea.Cells, 150d);
gcSpreadSheet1.Sheets[0].Rows[0].Background = new SolidColorBrush(Windows.UI.Colors.Gray);
gcSpreadSheet1.Sheets[0].Columns[0].Background = new SolidColorBrush(Windows.UI.Colors.Brown);
gcSpreadSheet1.Sheets(0).SetValue(0, 0, "value")
gcSpreadSheet1.Sheets(0).AddRows(0, 2)
gcSpreadSheet1.Sheets(0).AddColumns(0, 2)
gcSpreadSheet1.Sheets(0).SetRowHeight(0, GrapeCity.Xaml.SpreadSheet.Data.SheetArea.Cells, 50.0)
gcSpreadSheet1.Sheets(0).SetColumnWidth(0, GrapeCity.Xaml.SpreadSheet.Data.SheetArea.Cells, 150.0)
gcSpreadSheet1.Sheets(0).Rows(0).Background = New SolidColorBrush(Windows.UI.Colors.Gray)
gcSpreadSheet1.Sheets(0).Columns(0).Background = New SolidColorBrush(Windows.UI.Colors.Brown)
See Also

Reference

Worksheet Class
Worksheet Members
Overload List