Bug 55016 - XSSF event model. Cannot get cell name
Summary: XSSF event model. Cannot get cell name
Alias: None
Product: POI
Classification: Unclassified
Component: XSSF (show other bugs)
Version: 3.9-FINAL
Hardware: PC All
: P2 normal (vote)
Target Milestone: ---
Assignee: POI Developers List
Depends on:
Reported: 2013-05-24 14:09 UTC by Evgeni
Modified: 2013-05-27 11:59 UTC (History)
0 users

xlsx file with named cell. (7.65 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2013-05-24 14:09 UTC, Evgeni

Note You need to log in before you can comment on or make changes to this bug.
Description Evgeni 2013-05-24 14:09:14 UTC
Created attachment 30318 [details]
xlsx file with named cell.


Unfortunately I'm not able to get cell name using XSSF event model API. Please see the B2 column in the attached xlsx file.

The expected result that I expect to receive is cell id (B2 according to attached file) and cell name (COLUMN_NAME according to attached file)

Comment 1 Mark B 2013-05-24 16:24:45 UTC
I am assuming that you are using an SAX parser and a content handler to read the raw xml for the sheet but do need to be clear on this point so, may I ask how you are going about trying to retrieve the cell's name?

If you take a look at the raw xml markup for a workbook, then the names are usually stored in the workbook.xml file in an element called definedNames. This  element have children - each called definedName - which identifies the cell or cells the name refers to and specifies the name applied to that range of cells. If you are using the SAX parser/handler approach to process the sheet's contents, then I then you will also need to handle this extra wrinkle and parse the workbook.xml file also.
Comment 2 Evgeni 2013-05-27 11:41:41 UTC
Thank you for explanation. It's quite useful for me. It seems like my fault. I've not parsed workbook.xml. But I have already spent a lot of time trying to find anything related to this issue. 

Could you share the example if you have one, please?

Comment 3 Evgeni 2013-05-27 11:59:58 UTC
Finally i've found everything!

Thanks a lot for assistance!