Summary: | [PATCH] in POI 2.5: class DrawingRecord needs to define a clone method | ||
---|---|---|---|
Product: | POI | Reporter: | Stefan Moratz <stefan.moratz> |
Component: | HSSF | Assignee: | POI Developers List <dev> |
Status: | RESOLVED DUPLICATE | ||
Severity: | major | CC: | rich.renomeron |
Priority: | P3 | ||
Version: | 3.0-dev | ||
Target Milestone: | --- | ||
Hardware: | PC | ||
OS: | All | ||
Attachments: | Fix as patch |
Description
Stefan Moratz
2004-06-16 17:12:34 UTC
I had same error,when the cell has comment. It seems that the problem arise only if the sheet has comments. See also Massimiliano i get the same when the selected cell isn't A1 but another one (doesn't happen for all cells) to reproduce use my uploaded file in http://issues.apache.org/bugzilla/show_bug.cgi?id=27571 ah, i'm using 2.5.1-final i checked out the cvs version and implemented clone in DrawingRecord: public Object clone() { DrawingRecord drawingRecord = new DrawingRecord(); drawingRecord.recordData = (byte[]) recordData.clone(); return drawingRecord; } I don't really know, what a DrawingRecord is, my excel file doesn't contain drawings (but i think it did once). but this works for me, and if i write it to a new file, this doesn't make things worse. Created attachment 18892 [details] Fix as patch Here's the fix suggested in comment 5, as a patch against 3.0 alpha2. Pivot Tables clone just fine until you add a cell to the Page area. Even after deleting the item from the Pivot Table, trying to clone the sheet fails with the same error. |