NativeExcel2 for .Net Developer's Reference

IRangeColumn.DeleteMethod

Deletes a cell or a range of cells from the worksheet and shifts other cells left to replace deleted cells.

[Visual Basic]
SubDelete()
[C#]
voidDelete();
[C++]
voidDelete();
[JScript]
functionDelete();

Example

This example deletes column five from sheet one and shifts other cells left.

[C#]
 book.Worksheets[1].UsedRange.Columns[5].Delete(); 
[VisualBasic]
 book.Worksheets(1).UsedRange.Columns(5).Delete()
[C++]
 book->Worksheets->Item[1]->UsedRange->Columns->Item[5]->Delete(); 

See Also

IRangeColumn Interface | NativeExcel Namespace | Insert Method