i am a newbie to JSf
and Tomahawk Technology. In application i am having a datatable, i want store the information from he data table into a PDF format on a click of a button using Tomahawk
and SandBox
.Kindly Help.
views:
35answers:
3
A:
You may need iText for this.
Also see this - http://www.junlu.com/msg/281869.html
Padmarag
2010-02-25 10:43:21
+1
A:
Even better, use JasperReports. It uses iText behind the scene to export reports to PDF.
Boris Pavlović
2010-02-25 10:47:29
A:
As you have mentioned you are using sandbox, use exporterActionListener
component in the sandbox to export the data from data tabel into PDF. You need the itext-0.99.jar use the same version
Code sample
<!-- sandbox tag library declaration -->
<%@ taglib uri="http://myfaces.apache.org/sandbox" prefix="s"%>
.
. <!-- your data Tabel will be here -->
.
.
<h:commandButton value="Export as pdf">
<s:exporterActionListener for="Id of the Data Tabel" fileType="PDF" />
</h:commandButton>
Hari
2010-03-26 11:38:44