Bug 24183 - [PATCH] Added CLSID support for DirectoryNodes
Summary: [PATCH] Added CLSID support for DirectoryNodes
Status: RESOLVED DUPLICATE of bug 22195
Alias: None
Product: POI
Classification: Unclassified
Component: POIFS (show other bugs)
Version: 2.0-pre3
Hardware: Other other
: P3 enhancement (vote)
Target Milestone: ---
Assignee: POI Developers List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-10-28 16:50 UTC by Kirill Jacobson
Modified: 2004-11-16 19:05 UTC (History)
0 users



Attachments
[PATCH] CLSID support for DirectoryNodes (11.05 KB, patch)
2003-10-28 17:05 UTC, Kirill Jacobson
Details | Diff
[PATCH] CLSID support for DirectoryNodes (without sun collections) (10.84 KB, patch)
2003-10-29 23:02 UTC, Kirill Jacobson
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kirill Jacobson 2003-10-28 16:50:17 UTC
If you try to copy an Excel file with OLE objects (embeded, linked, commaind 
buttons, VBA macros) to another file using POI library then the links to these 
embeded objects are removed. 

Lets say you have Excel spreadsheet with a command button that associated with 
vba macro that pops up a message box. In the original Excel spreadsheet you 
click on the button, the vba code gets executed and message is displayed. You 
deep copy all the streams and storages from the original file to new compound 
storage file. You open this new file and you can see the button, but nothing 
happens if you click this button. It doesn't even change to pressed/unpressed 
state. 

This is beacause CLSIDs for the directories/storages are stripped out. 

I add getters and setters for CLSID to the Property object and DirectoryEntry 
inteface. They take CLSID as a string in the format that Windows Registry is 
using "{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}"

Kirill Jacobson
www.SoftArtisans.com
Comment 1 Kirill Jacobson 2003-10-28 17:05:03 UTC
Created attachment 8772 [details]
[PATCH] CLSID support for DirectoryNodes
Comment 2 Avik Sengupta 2003-10-28 17:41:12 UTC
Looks cool, but first reaction is, why the import for
com.sun.java.util.collections.* ??
Comment 3 Kirill Jacobson 2003-10-28 20:40:45 UTC
Oops, I forgot to replace this import back to java.utils. We use sun 
collections internaly. Should I submit another diff file? 
Comment 4 Kirill Jacobson 2003-10-29 23:02:07 UTC
Created attachment 8807 [details]
[PATCH] CLSID support for DirectoryNodes (without sun collections)
Comment 5 Avik Sengupta 2003-10-30 08:28:31 UTC
Thanks.. we have a feature freeze for a release this weekend.. This will have to
go in after the 2.0 release. 
Comment 6 Avik Sengupta 2003-10-30 16:48:15 UTC
Hey, is this the same as bug 22195 ? Sorry, we seem to have let that drop. 
Comment 7 Kirill Jacobson 2003-10-30 17:56:10 UTC
Yes, this is the same bug as 22195 (from Rainer Klute). I think that his patch 
(not mine) should be used. It reuses poi/hpsf/ClassID class and has a testcase. 
The only thing that is missing in Rainer's patch are classID getters and 
setters for for DirectoryNode and DirectoryEntry. I will add them as soon as 
the Rainer's patch is commited to source branch.
Comment 8 Avik Sengupta 2003-10-30 18:34:26 UTC

*** This bug has been marked as a duplicate of 22195 ***