The Application setting "Apache POI" makes sense for all OOXML packages 
produced by Apache POI.
I changed XSSF and XWPF to set it to "Apache POI" instead of "Microsoft Excel" and 
"Microsoft Office Word".

The AppVersion property can is not that important and can be omitted.

Excel 2007 and OpenOffice 3.1 have no problems opening such files.
Leif, would you please do the final check in Mac Excel 2008? The fix was 
committed in r802539.

Regards,
Yegor

On 7/30/09 12:19 PM, "David Fisher" <[email protected]> wrote:
As a project we should decide if -

(a) It is safe to make the Application setting "Apache POI". A test
would be to successfully open an XSSF file with consumers other than
Excel 12.2.0. This includes OpenOffice 3.0.

(b) If it is safe then I propose that we set the Application to
"Apache POI" and the AppVersion to the poi version - eg. "3.5-
beta7-20090731"

This is worth a discussion. Please respond if you have an opinion.


I did some experimenting with the newly release Excel 2008 12.2.1.  Here's
what I've found related to (b) above:

The following works on both Mac (12.2.1) /Windows Excel (12.0.6425.1000):

XSSFWorkbook wb = new XSSFWorkbook();
POIXMLProperties.ExtendedProperties ext =
wb.getProperties().getExtendedProperties();
ext.getUnderlyingProperties().setApplication("Apache POI");
ext.getUnderlyingProperties().setAppVersion("3.5");

This DOES NOT WORK on either version of Excel (mac or windows)

XSSFWorkbook wb = new XSSFWorkbook();
POIXMLProperties.ExtendedProperties ext =
wb.getProperties().getExtendedProperties();
ext.getUnderlyingProperties().setApplication("Apache POI");
ext.getUnderlyingProperties().setAppVersion("3.5-beta-7020090731");

After some experimenting, it seems that anything in the AppVersion field
except a digit or a "." causes the files to become unreadable by Excel.
i.e. 3.5.5 works, but 3.5.beta7 does not.  Also, it only allows two "."
values.  So, 3.5.5 works, but 3.5.5.0 does not.

I tried the following variations. All of the results were the SAME for both
windows/mac excel, which is nice.  OpenOffice 3.1 could open every one of
the variations.

3.5-beta7 (excel-NO) (openoffice-OK)
3-5 (excel-NO) (openoffice-OK)
3.5.beta7 (excel-NO) (openoffice-OK)
3.5.b (excel-NO) (openoffice-OK)
3.5.0.20090731 (excel-NO) (openoffice-OK)
3.5.0.1 (excel-NO) (openoffice-OK)

3.5 (excel-OK) (openoffice-OK)
3.5.0 (excel-OK) (openoffice-OK)
3.5.20090731 (excel-OK) (openoffice-OK)

According to the ECMA-376 Second Edition docs:

22.2.2.1 Application (Application Name)
This element specifies the name of the application that created this
document. The possible values for this element are defined by the W3C XML Schema string datatype.
22.2.2.2 AppVersion (Application Version)
This element specifies the version of the application which produced this
document. The content of this element shall be of the form XX.YYYY where X and Y
represent numerical values, or the document shall be considered
non-conformant. [Note: The contents of this element do not represent absolute values, but
rather qualify the contents of the Application element to differentiate
between different versions of the same producer. Applications should use
this information in an informative manner only (as document metadata). end
note] The possible values for this element are defined by the W3C XML Schema
string datatype.

Hope that helps,
--Leif






---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]




---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to