It seems like the MutablePropertySet(PropertySet) constructor re-arranges the custom document properties so that the destination file is corrupted (not sure if this is the reason for the corruption though). I just grabbed the source from the CVS, built it and tried out the WriteAuthorAndTitle example and got errors when I tried to add new custom doc properties to my destination file (in explorer). I am also unable to see the old custom doc props when I bring up the Properties dialog box in explorer.
Created attachment 10667 [details] Sample source and dest files used for WriteTitleAndAuthor
Before writing a section's properties HPSF now sorts them by their property IDs. Since I don't have M$ Word I cannot test this fix. Please try it out and let me know if it helps!
I didn't get an affirmation that the fix helped the reporter, but I also didn't get any complaints, so I close this bug.
Hi, Sorry for the long delay, I haven't been at the office for a while... The fix do arrange the properties by their id now, but I think (not sure here) that it is important to keep the order from the source document. I have checked in a text file with the output from ReadCustomPropertySets for both the source file test1.xls and the destination file test2.xls. No custom props are visible in test2.
Created attachment 12536 [details] Output from source and destination after WriteAuthorAndTitle
*** Bug 30956 has been marked as a duplicate of this bug. ***