I had some time and wrote the unit test and patch.
https://bz.apache.org/bugzilla/show_bug.cgi?id=60025
On Fri, Aug 19, 2016 at 8:31 AM, Javen O'Neal wrote:
> https://svn.apache.org/viewvc/poi/trunk/src/java/org/apache/poi/ss/usermodel/DataFormatter.java?revision=1753122&view=markup#l897
>
> Look
https://svn.apache.org/viewvc/poi/trunk/src/java/org/apache/poi/ss/usermodel/DataFormatter.java?revision=1753122&view=markup#l897
Looks like it isn't being uppercased. String.valueOf(false) -> "false"
Do you want to open a bug at https://bz.apache.org/bugzilla and submit
a patch with a unit test?
If I use the default format of the cell(Standard) and type 'FALSE' in this
cell, then I get the value 'false' in the cell by using formatCellValue method.
Actually, I hope that I can get the value 'FALSE', not lowercase 'false'.
Could I achieve this by using DataFormatter?
On 2016-08-19 10:48 (+
Yes. DataFormatter does what you want: get the string representation of the
cell contents (numeric, date, string, boolean, blank, error, formula)
On Aug 18, 2016 18:54, "陈 杨阳" wrote:
> Actually, I want to get the value in cells and change them to String in
> Java.(numeric -> String, string -> St
Actually, I want to get the value in cells and change them to String in
Java.(numeric -> String, string -> String, and so on).
Sometimes, I'm not sure what CellType it is. So I want to know the CellType at
first, and then I can convert them to String.
As you said, I can directly use DataFormatte