Pass thanks and regards ;)
---------- Forwarded message ----------
From: <[email protected]>
Date: 2011/9/23
Subject: Re: Simple API
To: Devin Han <[email protected]>
Many thanks, I also found from another example I came across
replacing
SpreadsheetDocument doc = SpreadsheetDocument.*newSpreadsheetDocument*();
Table table = doc.getTableList().get(0);
witth
doc = SpreadsheetDocument.*newSpreadsheetDocument*();
OfficeSpreadsheetElement officeSpreadsheet = doc.getContentRoot();
Node childNode = officeSpreadsheet.getFirstChild();
*while* (childNode != *null*) {
officeSpreadsheet.removeChild(childNode);
childNode = officeSpreadsheet.getFirstChild();
}
table = doc.addTable();
makes the messages go away, no idea why but I can live with that.
Otherwise many thanks for the project I have managed to code a whole
spreadsheet report together in a day using the help from the site. Now we
can support our users in both Excel and OpenOffice.
Please pass my thanks and regards to the Simple Team.
Regards,
Phill
*Devin Han <[email protected]>*
23/09/2011 07:37
To
[email protected]
cc
Subject
Re: Simple API
Hi Phill,
Congratulations! You are the first user who ask question after Simple API
moved to Apache. But no gift ;)
Please reference my comment:
2011/9/22 <*[email protected]* <[email protected]>>
I can't seem to find any sort of support forum for the Simple API stuff.
I have just started trying it out and put a simple bit of code in from the
tutorials
SpreadsheetDocument doc = SpreadsheetDocument.*newSpreadsheetDocument*();
Table table = doc.getTableList().get(0);
Row row = table.getRowByIndex(0);
row.getCellByIndex(0).setStringValue("one");
row.getCellByIndex(1).setStringValue("two");
doc.save("c:/temp/book.ods");
and it throws an error on stderr, the result actually works. Simple .6.6/odf
0.8.7
22-Sep-2011 11:48:35 org.odftoolkit.simple.style.DefaultStyleHandler
getTextPropertiesForRead
INFO: No explicit text properties definition is found!
The help and everything make no mention of this and google was not very
helpful and there is nothing in bugzilla.
It does not seem very simple is the first bit of code I follow from the
tuttorial throws and error.
Could you point me in the right direction for getting some help on using
this product.
Regards,
Phill
Don't worry about this log message. It is generated by the method
getTextPropertiesForRead() in
org.odftoolkit.simple.style.DefaultStyleHandler.
Logger.getLogger(CellStyleHandler.class.getName()).log(Level.INFO, "No
explicit text properties definition is found!", "");
When cell has no text style setting, this log will be printed (maybe we
should change its level to "DEBUG"). But I am sure it's doesn't mean your
code doesn't work well. It's just a tip or warning.
Any more question please send mail to:
*[email protected]*<[email protected]>,
more nice guys will help you in there.
If you need to create an issue, please access: *
https://issues.apache.org/jira/browse/ODFTOOLKIT*<https://issues.apache.org/jira/browse/ODFTOOLKIT>
.
In our website you can get more information: *
http://incubator.apache.org/odftoolkit/simple/index.html*<http://incubator.apache.org/odftoolkit/simple/index.html>
.
--
-Devin
--
-Devin