You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by bu...@apache.org on 2013/11/19 12:36:07 UTC

[Bug 55796] New: cellType is not override by integer value zero.

https://issues.apache.org/bugzilla/show_bug.cgi?id=55796

            Bug ID: 55796
           Summary: cellType is not override by integer value zero.
           Product: POI
           Version: 3.9
          Hardware: PC
            Status: NEW
          Severity: critical
          Priority: P2
         Component: XSSF
          Assignee: dev@poi.apache.org
          Reporter: bhargav.ce86@gmail.com

The following code fails to set the cell type by integer value zero. Other
types are properly set but zero number seems to have issues. The HSSF
Implimentation does not have this issue.

CODE
=====
//column is a short type variable set with 0,1,2,3,...
XSSFCell cell = row.createCell(column);
cell.setCellType(0)
system.out.println("cell type value : "+cell.getCellTyep);


OUTPUT
======
cell type value 3.


if we set cell type with integer value one.it will be override with one.
CODE
=====
XSSFCell cell = row.createCell(column);
cell.setCellType(1)
system.out.println("cell type value : "+cell.getCellTyep);


OUTPUT
======
cell type value 1.


please response me as soon as possible.
Thank you.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 55796] cellType is not override by integer value zero.

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=55796

Bhargav <bh...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW

--- Comment #2 from Bhargav <bh...@gmail.com> ---
I mean to say that cellTyep is not proper set with value zero.
For example:
------------
//public static final int CELL_TYPE_NUMERIC = 0;

XSSFCell cell = row.createCell(1);
system.out.println("Before - " + getCellType();)
cell.setCellType(XSSFCell.CELL_TYPE_NUMERIC);
system.out.println("After - " + getCellType();)

OUTPUT of above program
------------------------
Before - 3
After - 3

I can't understand what this happened. I set cellType with
CELL_TYPE_NUMERIC(means zero) and when i get cellType, it will return value 3.
how could it is possible.This issued only happened after change the POI-HSSF TO
POI-XSSF.The HSSF Implimentation does not have this issue.


For more information read below link :
---------------------------------------
http://apache-poi.1045710.n5.nabble.com/XSSF-cellType-setting-to-number-td5710637.html

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 55796] cellType is not override by integer value zero.

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=55796

Nick Burch <ap...@gagravarr.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO

--- Comment #3 from Nick Burch <ap...@gagravarr.org> ---
Setting a cell type on an empty cell without a value doesn't mean much though.
What happens if you set a cell type *and* a value?

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 55796] cellType is not override by integer value zero.

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=55796

Nick Burch <ap...@gagravarr.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO
                 OS|                            |All

--- Comment #1 from Nick Burch <ap...@gagravarr.org> ---
What happens if as well as setting the cell to be of type numeric, you also set
a numeric value with it? A cell type of 3 is blank, which is understandable for
a cell without any value...

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org