-
1. Re: Excel support
danielc.roth Feb 27, 2008 9:06 AM (in response to nickarls)There is always this thingy one could use in datatables:
http://myfaces.apache.org/sandbox/excelexport.html
However, copy/paste the seam email/pdf package and just do about the same shouldn't be that hard. I'll gladly develop something like that for seam, as soon as all my major deadlines (in March) are history :-)
-
2. Re: Excel support
nickarls Feb 27, 2008 9:44 AM (in response to nickarls)Cool! How do you vision the structure? Something (simplified) like
<e:workbook value="#{data}"> <e:workbookSettings/> <e:worksheet name="First sheet" <e:sheetSettings/> <e:column> <f:facet name="header"/> <e:cell data="> <e:cellFeatures/> <e:cellFormat/> </e:cell> </e:column> ... </e:worksheet> </e:workbook>
?
-
3. Re: Excel support
nickarls Feb 27, 2008 10:20 AM (in response to nickarls)In any case, the structure is more fixed than PDF so I think it would be possible to expose more features.
I'm somewhat familiar with JExcelAPI but haven't written a custom tag in my life so if you get as far as accessing the data, I might be able to help.
-
4. Re: Excel support
baz Feb 27, 2008 10:36 AM (in response to nickarls)Here is my personal opinion for your question:
It would be very, very nice and appreciated if a normal datatable could be exported to csv data.
That should have priority, but i believe that such an behaviour should be implemented outside of seam (richfaces, or directly by the jsf ri)That is exactly was s:excelExport is doing.
But i can not imagine any usecase where it is useful to have iText duplicated for Excel.
In any case, before downloading the data we will have to present the data to the user, so that he can decide if he wants to get it.
In the rare cases, where we only deliver the csv file we are dealing directly with the csv api. However, in this cases we could imagine to use such an extension if it exists.
Ciao,
Carsten -
5. Re: Excel support
pmuir Feb 27, 2008 11:06 AM (in response to nickarls)This comes up occasionally as a feature request, and whilst it's not on the priority list for us, if it came in as a community contribution, we would certainly find the time to review and commit it I think!
-
6. Re: Excel support
norman Feb 28, 2008 5:56 PM (in response to nickarls)I thought someone already opened a JIRA for this, but I guess not. I agree with Pete, if someone wants to contribute the work, I'm sure we'd be happy to use it.
-
7. Re: Excel support
svadu Feb 28, 2008 7:07 PM (in response to nickarls)Btw, AFAIK, if you just change the content type to 'application/vnd.ms-excel' IE (since this is vendor specific) should be able to automatically import xhtml in excel. Would this work for you?
-
8. Re: Excel support
mono Feb 28, 2008 7:08 PM (in response to nickarls)Hi Niklas,
Another option to work with Excel files:
I have used Apache POI API to read content from a db query and then put it on an excel file. It works very good and is easy to use.
I think you can use it, calling a method from a command button.
I have some examples, and ther are more in the FAQ section in the project homepage.
May be this is more complicated than the myface's solution... i don't know... :) -
9. Re: Excel support
nickarls Feb 28, 2008 8:25 PM (in response to nickarls)That it one option but my experience is that JExcelAPI is ahead when it comes to performance and memory usage and I have never seen any proof otherwise.
-
10. Re: Excel support
nickarls Feb 28, 2008 8:30 PM (in response to nickarls)I think that doing that would enable you to dump CSV straight into Excel too but I'm not fond of doing browser tricks (I got the idea that IE is not that popular around here).
And I don't think fonts, formatting etc would be available through that path. If it's going to be done it might as well be done as complete as possible.
One option could perhaps be writing it in OpenWorkbook or whatever the MS XML format was called but I'm not aware of any good libraries for it and last time I checked there was some licensing restrictions for writing them.
-
11. Re: Excel support
svadu Feb 28, 2008 10:59 PM (in response to nickarls)Well we had pretty good results with jspx+struts....
-
12. Re: Excel support
nickarls Feb 29, 2008 9:53 AM (in response to nickarls)In the absence of PM:s on this forum:
Daniel, kan du maila mig på nickarls*gmail.com så kan vi bolla med lite idéer?
-