GrapeCity.Xaml.SpreadSheet.Data
RemoveAt Method (WorksheetCollection)
Example 


The zero-based index of the sheet to remove.
Removes the sheet at the specified index.
Syntax
'Declaration
 
Public Overrides Sub RemoveAt( _
   ByVal index As Integer _
) 
'Usage
 
Dim instance As WorksheetCollection
Dim index As Integer
 
instance.RemoveAt(index)
public override void RemoveAt( 
   int index
)

Parameters

index
The zero-based index of the sheet to remove.
Exceptions
ExceptionDescription
System.ArgumentOutOfRangeExceptionindex is not a valid index in the collection.
System.NotSupportedExceptionThe collection is read-only.
Example
This example uses the RemoveAt method.
//Remove some sheets
gcSpreadSheet1.SheetCount = 5;
gcSpreadSheet1.Sheets.Remove(gcSpreadSheet1.Sheets[1]);
gcSpreadSheet1.Sheets.RemoveAt(0);
'Remove some sheets
GcSpreadSheet1.SheetCount = 5
GcSpreadSheet1.Sheets.Remove(GcSpreadSheet1.Sheets(1))
GcSpreadSheet1.Sheets.RemoveAt(0)
Requirements

Target Platforms: Windows Server 2012, Windows RT

See Also

Reference

WorksheetCollection Class
WorksheetCollection Members

 

 


Copyright © GrapeCity, inc. All rights reserved.

Support Options