title: Adding a sheet in an existing excel file
body: <p>I have tried in various ways to add an Excel spreadsheet. But the problem is always the same.</p>
  
  <p>I tried the codes proposed here,</p>
  
  <ul>
  <li><a href="https://stackoverflow.com/questions/17383955/add-a-sheet-into-existing-excel-file">Add a sheet into existing excel file</a></li>
  <li><a href="https://stackoverflow.com/questions/12436243/creating-new-sheet-in-existing-excel-workbook-using-apache-poi-for-java">Creating New Sheet In Existing Excel Workbook Using Apache POI for Java</a></li>
  </ul>
  
  <p>The problem :</p>
  
  <pre><code>Exception in thread "main" java.lang.ClassCastException: org.apache.poi.hssf.record.BOFRecord cannot be cast to org.apache.poi.hssf.record.TabIdRecord
      at org.apache.poi.hssf.model.InternalWorkbook.fixTabIdRecord(InternalWorkbook.java:792)
      at org.apache.poi.hssf.model.InternalWorkbook.checkSheets(InternalWorkbook.java:742)
      at org.apache.poi.hssf.model.InternalWorkbook.setSheetName(InternalWorkbook.java:579)
      at org.apache.poi.hssf.usermodel.HSSFWorkbook.createSheet(HSSFWorkbook.java:748)
      at org.apache.poi.hssf.usermodel.HSSFWorkbook.createSheet(HSSFWorkbook.java:101)
      at ReadTry.main(ReadTry.java:28)
  </code></pre>