Spread Silverlight Documentation
SetCustomName(String,Int32,Int32,Int32,Int32) Method
Example 


GrapeCity.Windows.SpreadSheet.Data Namespace > Worksheet Class > SetCustomName Method : SetCustomName(String,Int32,Int32,Int32,Int32) Method
The set name.
The start row index.
The start column index.
The number of rows.
The number of columns.
Sets a custom name for the specified area.
Syntax
'Declaration
 
Public Overloads Sub SetCustomName( _
   ByVal name As System.String, _
   ByVal row As System.Integer, _
   ByVal column As System.Integer, _
   ByVal rowCount As System.Integer, _
   ByVal columnCount As System.Integer _
) 
'Usage
 
Dim instance As Worksheet
Dim name As System.String
Dim row As System.Integer
Dim column As System.Integer
Dim rowCount As System.Integer
Dim columnCount As System.Integer
 
instance.SetCustomName(name, row, column, rowCount, columnCount)
public void SetCustomName( 
   System.string name,
   System.int row,
   System.int column,
   System.int rowCount,
   System.int columnCount
)

Parameters

name
The set name.
row
The start row index.
column
The start column index.
rowCount
The number of rows.
columnCount
The number of columns.
Example
This example uses the SetCustomName method.
gcSpreadSheet1.Sheets[0].SetValue(0, 0, 1);
gcSpreadSheet1.Sheets[0].SetValue(0, 1, 2);
gcSpreadSheet1.Sheets[0].SetValue(0, 2, 3);
gcSpreadSheet1.Sheets[0].SetCustomName("customName1", 0, 0, new CalcDoubleExpression(12));
gcSpreadSheet1.Sheets[0].SetCustomName("customName2", 0, 0, "Average(20,45)");
gcSpreadSheet1.Sheets[0].SetCustomName("customName3", 0, 0, 1, 3);
gcSpreadSheet1.Sheets[0].SetFormula(1, 0, "customName1");
gcSpreadSheet1.Sheets[0].SetFormula(1, 1, "customName2");
gcSpreadSheet1.Sheets[0].SetFormula(1, 2, "sum(customName3)");
GcSpreadSheet1.Sheets(0).SetValue(0, 0, 1)
GcSpreadSheet1.Sheets(0).SetValue(0, 1, 2)
GcSpreadSheet1.Sheets(0).SetValue(0, 2, 3)
GcSpreadSheet1.Sheets(0).SetCustomName("customName1", 0, 0, New CalcDoubleExpression(12))
GcSpreadSheet1.Sheets(0).SetCustomName("customName2", 0, 0, "Average(20,45)")
GcSpreadSheet1.Sheets(0).SetCustomName("customName3", 0, 0, 1, 3)
GcSpreadSheet1.Sheets(0).SetFormula(1, 0, "customName1")
GcSpreadSheet1.Sheets(0).SetFormula(1, 1, "customName2")
GcSpreadSheet1.Sheets(0).SetFormula(1, 2, "sum(customName3)")
See Also

Reference

Worksheet Class
Worksheet Members
Overload List