https://issues.apache.org/bugzilla/show_bug.cgi?id=51989
Yegor Kozlov <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |INVALID --- Comment #1 from Yegor Kozlov <[email protected]> 2012-02-27 09:18:08 UTC --- By default, Row#getCell returns what is physically stored in the workbook stream and in your case it is null. However, you can control what to do when getting missing or blank cells with Workbook.setMissingCellPolicy(MissingCellPolicy missingCellPolicy); there are three options: /** Missing cells are returned as null, Blank cells are returned as normal */ public static final MissingCellPolicy RETURN_NULL_AND_BLANK = new MissingCellPolicy(); /** Missing cells are returned as null, as are blank cells */ public static final MissingCellPolicy RETURN_BLANK_AS_NULL = new MissingCellPolicy(); /** A new, blank cell is created for missing cells. Blank cells are returned as normal */ public static final MissingCellPolicy CREATE_NULL_AS_BLANK = new MissingCellPolicy(); If you expect a blank cell then call workbook.setMissingCellPolicy(MissingCellPolicy.CREATE_NULL_AS_BLANK ); after constructing your workbook. Yegor -- Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
