Bug 33153

Summary: Need way to get cell num in excel form eg. C11, GH239 etc.
Product: POI Reporter: Amol Deshmukh <amolweb>
Component: HSSFAssignee: POI Developers List <dev>
Status: RESOLVED INVALID    
Severity: enhancement CC: amolweb
Priority: P3    
Version: 2.5-FINAL   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   

Description Amol Deshmukh 2005-01-18 17:09:25 UTC
Currently, in HSSF, there appears to be no way to get the cell number in excel
format (eg. C11, GH239 etc.) that would be useful in generating formulas when
dynamically creating excel sheets.

For this, HSSFCell class seems to be the most natural place to put a method like:
          public String getCellRefString() {...}
that would return a String of the form: AD11 or whatever is appropriate.
(Basically convert the cellNum to base 26 (A-Z) and append the row num)
Comment 1 Avik Sengupta 2005-01-28 19:08:43 UTC
new org.apache.poi.hssf.util.CellReference(row,col).toString()