public Hoja CreateNewHoja(string name) { var ultimahoja = this.iWorkbook.Sheets.OfType <Worksheet>().LastOrDefault(); var iWorksheet = this.iWorkbook.Sheets.Add(ultimahoja ?? Type.Missing, Type.Missing, Type.Missing, XlSheetType.xlWorksheet); var oHoja = new Hoja(iWorksheet); oHoja.Name = name; this.Hojas.Add(oHoja); return(oHoja); }
public void DeleteHoja(Hoja hoja) { hoja.Delete(); this.Hojas.Remove(hoja); }