DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=32830>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=32830

           Summary: Excel is corrupted when I try adding HYPERLINK formulas
                    with long urls
           Product: POI
           Version: 2.5
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: major
          Priority: P2
         Component: HSSF
        AssignedTo: [email protected]
        ReportedBy: [EMAIL PROTECTED]


Excel is corrupted when I try adding HYPERLINK formulas with long urls.
The code is:

  col1.setCellType(HSSFCell.CELL_TYPE_FORMULA);                        
  String formula = "HYPERLINK(\"" +  url + "\"" + ")";
  col1.setCellFormula(formula);                                    

This creats a corrupt Excel for the url:
http://www.fundacioncondor.org.ar/sitio/modules/My_eGallery/public/wamu/index.p
hp?MfcISAPICommand=VerifyFPP&UsingSSL=1&login=&pass=

For a the URL:
wwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwww
wwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwww
I got the following Exception:

java.lang.ArrayIndexOutOfBoundsException: 2378
        at org.apache.poi.util.StringUtil.putCompressedUnicode
(StringUtil.java:196)
        at org.apache.poi.hssf.record.formula.StringPtg.writeBytes
(StringPtg.java:97)
        at org.apache.poi.hssf.record.FormulaRecord.serializePtgs
(FormulaRecord.java:407)
        at org.apache.poi.hssf.record.FormulaRecord.serialize
(FormulaRecord.java:361)
        at 
org.apache.poi.hssf.record.aggregates.FormulaRecordAggregate.serialize
(FormulaRecordAggregate.java:84)
        at 
org.apache.poi.hssf.record.aggregates.ValueRecordsAggregate.serialize
(ValueRecordsAggregate.java:153)
        at org.apache.poi.hssf.model.Sheet.serialize(Sheet.java:815)
        at org.apache.poi.hssf.usermodel.HSSFWorkbook.getBytes
(HSSFWorkbook.java:794)
        at org.apache.poi.hssf.usermodel.HSSFWorkbook.write
(HSSFWorkbook.java:732)
        at cyota.fraudaction.util.AOLDailyResultSender.main
(AOLDailyResultSender.java:98)



Other than that it's super. Great job!

Oded

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to