Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to fix cannot resolve "CELL_TYPE_BLANK"?

Tags:

java

I'm trying to read a xlsx file in my app. I'm using Apache POI 4.0.1. I'm getting an error:

cannot resolve symbol CELL_TYPE_BLANK"

Please tell me the solution.

like image 681
Mohan Avatar asked Oct 25 '25 22:10

Mohan


1 Answers

The constant you're using no longer exists. From the Apache POI 3.17 Javadoc of Cell.CELL_TYPE_BLANK:

CELL_TYPE_BLANK

@Deprecated
@Removal(version="4.0")
static final int CELL_TYPE_BLANK

Deprecated. POI 3.15 beta 3. Use CellType.BLANK instead.
Blank Cell type (3)

As indicated by @Removal(version="4.0"), it was scheduled to be removed in POI 4 and it has been removed. You need to use CellType.BLANK instead.

like image 96
Mark Rotteveel Avatar answered Oct 27 '25 13:10

Mark Rotteveel