poi-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 20881] New: - error occured in MS Excel:"Error in file: some number formats may be lost"
Date Wed, 18 Jun 2003 17:46:02 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=20881>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=20881

error occured in MS Excel:"Error in file: some number formats may be lost"

           Summary: error occured in MS Excel:"Error in file: some number
                    formats may be lost"
           Product: POI
           Version: 1.5.1
          Platform: PC
        OS/Version: Windows NT/2K
            Status: NEW
          Severity: Critical
          Priority: Other
         Component: HSSF
        AssignedTo: poi-dev@jakarta.apache.org
        ReportedBy: pjanouskovec@cscploenzke.de


Hello,
I have problem with HSSF component. I use MS Office 2000 (Czech localize). When 
I read and write workbook:
        POIFSFileSystem fs      =
                new POIFSFileSystem(new FileInputStream("c:\\workbook1.xls"));
        HSSFWorkbook wb = new HSSFWorkbook(fs);
        HSSFSheet sheet = wb.getSheetAt(0);
        //HSSFSheet sheet1 = wb.getSheetAt(1);
        HSSFRow row = sheet.getRow(3);
        HSSFCell cell = row.getCell((short)3);
        if (cell == null)
            cell = row.createCell((short) 2);
        cell.setCellType(HSSFCell.CELL_TYPE_NUMERIC);
        cell.setCellValue(80);

        // Write the output to a file
        FileOutputStream fileOut = new FileOutputStream("workbook2.xls");
        wb.write(fileOut);
        fileOut.close();
When I open workbook2.xls in MS Excel error occured in MS Excel "Error in file: 
some number formats may be lost" and some data are losted in last sheet (I have 
two sheets in workbook- first sheet is OK, but second sheet have some data 
lost). I try use MS Excel 97, but I get same result.
Do you have any idea?
Best Regards
Pavel

Mime
View raw message