You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by jamestthomas <ja...@comcast.net> on 2011/02/01 16:35:51 UTC

Re: POI from Excel 2000 to Excel 2010 issues. (Edited out previous)

Nick, 
>If you mean you create a HSSFWorkbook using a POIFSFileSystem constructor, 
>then that's your only way, yes. Any problem is likely to be with the low 
>level records that HSSF writes, rather than anything in the POIFS layer 

Yes, this is what I meant. If there is a problem with those low level records written by HSSF, I am not sure how I can identify the problem. I have found that by simply downloading the template, which includes sample data and all the macros, from webContent, it opens fine. Currently I have been simplifying the macro to no avail. Also, on the server side, in the Java, I removed all code that writes any additional data to the file so I am simply creating it. 
POIFSFileSystem fs = new POIFSFileSystem(new FileInputStream(RTC_global.templatePath + LibraryData.SBOM_IMPORT_MACRO_TEMPLATE)); 
wb = new HSSFWorkbook(fs); 
Then writing it out 
bos = new BufferedOutputStream(res.getOutputStream()); 

wb.write(bos); 
bos.close(); 
No luck with this. It seems POI is not fully compatible with Office 2010 and there is an issue with low level differences. I have a work around for our users whcih is to download to a "trusted Location". Do you know if adding a certificate of some sort to the template might replicate downloading to a trusted location? The file, despite all the dire warnings and the obvious difference noticed by Excel, does still work when opened. We are trying to make this seamless for our users. Any other thoughts or suggestions are most welcome. 

Jim Thomas 




If you reply to this email, your message will be added to the discussion below: http://apache-poi.1045710.n5.nabble.com/POI-from-Excel-2000-to-Excel-2010-issues-tp3365053p3366071.html 
To unsubscribe from POI from Excel 2000 to Excel 2010 issues., click here . 
-- 
View this message in context: http://apache-poi.1045710.n5.nabble.com/POI-from-Excel-2000-to-Excel-2010-issues-tp3365053p3366418.html
Sent from the POI - Dev mailing list archive at Nabble.com.

Re: POI from Excel 2000 to Excel 2010 issues. (Edited out previous)

Posted by David Fisher <df...@jmlafferty.com>.
>> Yegor and I always use and copy an empty HSSFWorkbook that has a digitally signed Macro in it. 
> 
>> HSSFWorkbook wb = new HSSFWorkbook(new FileInputStream(RTC_global.templatePath + LibraryData.SBOM_IMPORT_MACRO_TEMPLATE)); 
> 
>> Does this work for you? 
> 
> 
> Hello Dave, That sounds like a home run solution. I would ask how to digitally sign the macro but that sounds like another question for another forum.

http://www.google.com/search?btnG=1&pws=0&q=signing+excel+macros

> I was thinking that was what I might have to do. One question, if you happen to know, did you implement the digitally signed macro to alleviate problems like I have mentioned? 

Yes, it helps with warnings and tight corporate security policies. It may even be necessary for Excel 2010. (I am not sure.) A self-signed certificate may not be enough, one issued by a certificate authority may be required.

Regards,
Dave

> 
> Sincerely, James 
> 
> 
> 
> 
> 
> 
> If you reply to this email, your message will be added to the discussion below: http://apache-poi.1045710.n5.nabble.com/POI-from-Excel-2000-to-Excel-2010-issues-tp3365053p3366513.html 
> To unsubscribe from POI from Excel 2000 to Excel 2010 issues., click here . 
> -- 
> View this message in context: http://apache-poi.1045710.n5.nabble.com/POI-from-Excel-2000-to-Excel-2010-issues-tp3365053p3366652.html
> Sent from the POI - Dev mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


Re: POI from Excel 2000 to Excel 2010 issues. (Edited out previous)

Posted by jamestthomas <ja...@comcast.net>.
>Yegor and I always use and copy an empty HSSFWorkbook that has a digitally signed Macro in it. 

>HSSFWorkbook wb = new HSSFWorkbook(new FileInputStream(RTC_global.templatePath + LibraryData.SBOM_IMPORT_MACRO_TEMPLATE)); 

>Does this work for you? 


Hello Dave, That sounds like a home run solution. I would ask how to digitally sign the macro but that sounds like another question for another forum. I was thinking that was what I might have to do. One question, if you happen to know, did you implement the digitally signed macro to alleviate problems like I have mentioned? 

Sincerely, James 






If you reply to this email, your message will be added to the discussion below: http://apache-poi.1045710.n5.nabble.com/POI-from-Excel-2000-to-Excel-2010-issues-tp3365053p3366513.html 
To unsubscribe from POI from Excel 2000 to Excel 2010 issues., click here . 
-- 
View this message in context: http://apache-poi.1045710.n5.nabble.com/POI-from-Excel-2000-to-Excel-2010-issues-tp3365053p3366652.html
Sent from the POI - Dev mailing list archive at Nabble.com.

Re: POI from Excel 2000 to Excel 2010 issues. (Edited out previous)

Posted by David Fisher <df...@jmlafferty.com>.
Hi Jim,

>> If you mean you create a HSSFWorkbook using a POIFSFileSystem constructor, 
>> then that's your only way, yes. Any problem is likely to be with the low 
>> level records that HSSF writes, rather than anything in the POIFS layer 
> 
> Yes, this is what I meant. If there is a problem with those low level records written by HSSF, I am not sure how I can identify the problem. I have found that by simply downloading the template, which includes sample data and all the macros, from webContent, it opens fine. Currently I have been simplifying the macro to no avail. Also, on the server side, in the Java, I removed all code that writes any additional data to the file so I am simply creating it. 
> POIFSFileSystem fs = new POIFSFileSystem(new FileInputStream(RTC_global.templatePath + LibraryData.SBOM_IMPORT_MACRO_TEMPLATE)); 
> wb = new HSSFWorkbook(fs); 
> Then writing it out 
> bos = new BufferedOutputStream(res.getOutputStream()); 
> 
> wb.write(bos); 
> bos.close(); 
> No luck with this. It seems POI is not fully compatible with Office 2010 and there is an issue with low level differences. I have a work around for our users whcih is to download to a "trusted Location". Do you know if adding a certificate of some sort to the template might replicate downloading to a trusted location? The file, despite all the dire warnings and the obvious difference noticed by Excel, does still work when opened. We are trying to make this seamless for our users. Any other thoughts or suggestions are most welcome. 

Yegor and I always use and copy an empty HSSFWorkbook that has a digitally signed Macro in it.

HSSFWorkbook wb = new HSSFWorkbook(new FileInputStream(RTC_global.templatePath + LibraryData.SBOM_IMPORT_MACRO_TEMPLATE));

Does this work for you?

Regards,
Dave


> 
> Jim Thomas 
> 
> 
> 
> 
> If you reply to this email, your message will be added to the discussion below: http://apache-poi.1045710.n5.nabble.com/POI-from-Excel-2000-to-Excel-2010-issues-tp3365053p3366071.html 
> To unsubscribe from POI from Excel 2000 to Excel 2010 issues., click here . 
> -- 
> View this message in context: http://apache-poi.1045710.n5.nabble.com/POI-from-Excel-2000-to-Excel-2010-issues-tp3365053p3366418.html
> Sent from the POI - Dev mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org