Spreadsheet.DeleteCases

This function deletes the specified range of cases from the spreadsheet.

Syntax Parameters Return Value
Sub Spreadsheet.DeleteCases( _
    From As Integer, _
    To As Integer)
  • From [in]

The beginning of the range of cases to delete.

Type: Integer

  • To [in]

The end of the range of cases to delete.

Type: Integer

This function does not return a value.

SVB Example

Deleting cases and variables from a spreadsheet:

Option Base 1
Option Explicit
Sub Main
    Dim spr As Spreadsheet
    'assigns the active spreadsheet to the object spr
    Set spr = ActiveSpreadsheet
    'deletes cases 1-5 from the spreadsheet
    spr.DeleteCases(1,5)
    'deletes variables 1-5 from the spreadsheet
    spr.DeleteVariables(1,5)
End Sub