1 2 3 4 Previous Next 52 Replies Latest reply on Mar 1, 2011 4:28 PM by psramkumar.ps.ramkumar.gmail.com Go to original post
      • 45. Re: export to pdf or excel from rich:dataTable
        sureshgudapati

        hi,
        i am using following jarfiles for excel export web application:


        jboss-seam2.1
        1)jboss-seam-excel.jar
        2)jboss-seam.jar
        3)jboss-seam-ui.jar
        4)jboss-el.jar


        richfaces-3.2.1
        1)richfaces-api-3.2.1.GA.jar
        2)richfaces-impl-3.2.1.GA.jar
        3)richfaces-ui-3.2.1.GA.jar


        But i am getting following error:


        Error logs:
        The class 'org.jboss.seam.Namespace' does not have the property 'excelExporter'


        Could you please provide me the help on this issue? how to resolve this,... what jar files i need to use? and special setting on need to made on web.xml??

        • 46. Re: export to pdf or excel from rich:dataTable

          Look in the other thread where you asked the same question.

          • 47. Re: export to pdf or excel from rich:dataTable
            sathishavunoori
            hi nicklas
            i was new to seam,
            i want to convert an excel (*.xls) file to xml file.
            Can you please guide me with the necessary libraries how can i do this?


            Thanks in advance for your greate help
            sathish
            • 48. Re: export to pdf or excel from rich:dataTable
              nickarls

              Not really a seam question but



              1. Grab JExcelapi from http://jexcelapi.sourceforge.net/ and read through the docs

              2. Write code that iterates over the data in the xls and outputs to xml (coding left as an exercise for the reader)

              • 49. Re: export to pdf or excel from rich:dataTable
                holly_bony
                What about export to PDF without use <p:...>. Similar to

                org.jboss.seam.excel.excelExporter.export(...)    ?
                • 50. Re: export to pdf or excel from rich:dataTable
                  rokual

                  I am new to seam and have a similar functionality described in the thread.


                  I am trying to create an excel out of rich:datable.



                  I did add
                  1. seam-excel.jar, jxl.jar into my lib path.
                  2. Added DocumentStoreServlet in the web.xml
                  3. Added the code similar to below in the jsp.




                  <h:commandLink value="Export" action="#{org.jboss.seam.excel.excelExporter.export('searchForm:searchResultsTable')}"/>   



                              
                                                                      




                  When I execute,
                  I receive the following error


                  The function export must be used with a prefix when a default namespace is not specified.


                  I even defined the default namespace as


                  <html xmlns=""http://jboss.com/products/seam/excel">





                  I feel like I am missing something critical and simple. Can you please help me.



                  Are there any steps documented some where , if not can you please put them here, which will guide me in achieving the functinality

                  • 51. Re: export to pdf or excel from rich:dataTable
                    psramkumar.ps.ramkumar.gmail.com

                    any one worked with PDF Export similar way ? please add it in the post, that would help lots of developers.. including me


                    thanks

                    • 52. Re: export to pdf or excel from rich:dataTable
                      psramkumar.ps.ramkumar.gmail.com

                      Here we go...... the PDF Export


                      Create a file named exportPdf.xhtml use below code





                      <p:document type="PDF" xmlns:p="http://jboss.com/products/seam/pdf"
                           xmlns:ui="http://java.sun.com/jsf/facelets"
                           xmlns:h="http://java.sun.com/jsf/html">
                           <p:table columns="4" headerRows="1" widthPercentage="95"
                                spacingBefore="10">
                                <p:cell backgroundColor="#EEEEEE">File Index</p:cell>
                                <p:cell backgroundColor="#EEEEEE">File Name</p:cell>
                                <p:cell backgroundColor="#EEEEEE">File Size</p:cell>
                                <p:cell backgroundColor="#EEEEEE">File Date</p:cell>
                                <ui:repeat var="fileBean" value="#{mediationBeanHome.beanList}"
                                     varStatus="inx">
                                     <p:cell>
                                          <p:text value="#{fileBean.id+1}" />
                                     </p:cell>
                                     <p:cell>
                                          <p:text value="#{fileBean.fileName}" />
                                     </p:cell>
                                     <p:cell>
                                          <p:text value="#{fileBean.fileSize/1000} Kb" />
                                     </p:cell>
                                     <p:cell>
                                          <p:text value="#{fileBean.fileDate}" />
                                     </p:cell>
                                </ui:repeat>
                           </p:table>
                      </p:document>



                      use the below code as export PDF link




                      <h:commandLink target="#" action="/exportPdf.seam" rendered="#{not empty mediationBeanHome.beanList}" >
                           <h:graphicImage alt="Export XLS" url="/img/pdf.gif" title="Export table to PDF"/>
                      </h:commandLink>




                      Think this might work for all u guys


                      Thanks


                      1 2 3 4 Previous Next