search

Home  >  Q&A  >  body text

java - poi导出Excel时设置数据格式为double类型。

导出数据为Excel的时候,如何设置Excel的数据格式为double格式

大家讲道理大家讲道理2892 days ago548

reply all(1)I'll reply

  • PHPz

    PHPz2017-04-18 09:08:42

    As for the POI3 version, the types supported by the cell are
    @see #CELL_TYPE_NUMERIC

    • @see #CELL_TYPE_STRING

    • @see #CELL_TYPE_FORMULA

    • @see #CELL_TYPE_BLANK

    • @see #CELL_TYPE_BOOLEAN

    • @see #CELL_TYPE_ERROR
      Of course, it should be noted that when using NUMERIC, you need to consider whether it is a date. You can use DateUtil.isCellDateFormatted(cell) to verify whether it is a date type

    reply
    0
  • Cancelreply