Spread WinForms 15
GrapeCity.Spreadsheet Assembly / GrapeCity.Spreadsheet.Slicers Namespace / ISlicers Interface / Add Method
A GrapeCity.Spreadsheet.IWorksheet object where the resulting slicer will be placed. The destination sheet must be in the workbook that contains the Slicers object specified by expression.
The name of the slicer. Spread automatically generates a name if the parameter is missing. The name must be unique across all slicers within a workbook.
The caption of the slicer.
The initial horizontal position of the slicer, in pixels, relative to the upper-left corner of cell A1 on a worksheet.
The initial vertical position of the slicer, in pixels, relative to the upper-left corner of cell A1 on a worksheet.
The initial width, in pixels, of the slicer control.
The initial height, in pixels, of the slicer control.


In This Topic
Add Method (ISlicers)
In This Topic
Creates a new slicer.
Syntax
'Declaration
 
Function Add( _
   ByVal worksheet As IWorksheet, _
   Optional ByVal name As String, _
   Optional ByVal caption As String, _
   Optional ByVal x As Integer, _
   Optional ByVal y As Integer, _
   Optional ByVal width As Integer, _
   Optional ByVal height As Integer _
) As ISlicer
 
'Usage
 
Dim instance As ISlicers
Dim worksheet As IWorksheet
Dim name As String
Dim caption As String
Dim x As Integer
Dim y As Integer
Dim width As Integer
Dim height As Integer
Dim value As ISlicer
 
value = instance.Add(worksheet, name, caption, x, y, width, height)

Parameters

worksheet
A GrapeCity.Spreadsheet.IWorksheet object where the resulting slicer will be placed. The destination sheet must be in the workbook that contains the Slicers object specified by expression.
name
The name of the slicer. Spread automatically generates a name if the parameter is missing. The name must be unique across all slicers within a workbook.
caption
The caption of the slicer.
x
The initial horizontal position of the slicer, in pixels, relative to the upper-left corner of cell A1 on a worksheet.
y
The initial vertical position of the slicer, in pixels, relative to the upper-left corner of cell A1 on a worksheet.
width
The initial width, in pixels, of the slicer control.
height
The initial height, in pixels, of the slicer control.

Return Value

The created ISlicer object.
See Also