//Instantiate a Workbook object.Workbook workbook = new Workbook();//Load a template file.workbook.Open("d:\\test\\MyBook.xls");//Get the first worksheet in the book.Worksheet sheet = workbook.Worksheets[0];//Insert 10 rows at row index 2 (insertion starts at 3rd row)sheet.Cells.InsertRows(2, 10);//Delete 5 rows now. (8th row - 12th row)sheet.Cells.DeleteRows(7, 5);//Save the excel file.workbook.Save("d:\\test\\MyBook.xls");