HSSF POI : How to know if data in cell is of Type Date?
问题 Currently i have my code as bean.setREPO_DATE(row.getCell(16).getDateCellValue()); it works fine if cell is formatted as date in excel. However it also converts some integer or long like 1234 or 5699 to date. I know the reason behind this too. However i want to apply a check before executing above line. Something like this if(row.getCell(16).isOfDateFormat){ bean.setREPO_DATE(row.getCell(16).getDateCellValue()); } Please Guide me.. Thanks in Advance ! 回答1: Try this, use import org.apache.poi