cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Velychko <>
Subject Re: Problems with HSSF Serializer
Date Tue, 27 Jan 2004 14:26:50 GMT

Is the exception reproduced if you serialize to XML instead of XLS?
If it is so try to comment <map:transform .../> and check your result.

EA> Hi Cocoon users,
EA> I'm new to cocoon framework. In my office, I want to
EA> use the cocoon framework to export data to different
EA> data formats(especially Excel format). 
EA> My web application is based on stuts framework and the
EA> struts-cocoon plugin. I believe that the choice is
EA> completely adapted, but I have some problems when I
EA> want to use HSSF Serializer for Exports. 
EA> The errror message that I have let think that Xalan
EA> does not find my xslt style sheet: 

EA> Original Exception: java.lang.RuntimeException:
EA> Cannot find the sheet object
EA>         at
EA>         at
EA> org.apache.xalan.transformer.TransformerHandlerImpl.endDocument(
EA>         at
EA> org.apache.cocoon.xml.AbstractXMLPipe.endDocument(
EA>         at
EA> org.apache.cocoon.transformation.TraxTransformer.endDocument(
EA>         at
EA> webmx.common.fwk.cocoon.generator.BeanGenerator.generate(Unknown
EA> Source).
EA> As you can see I'm using my own generator wich
EA> serialises the beans passed to cocoon from the struts
EA> actions through the session. 

EA> Wich is astonishing is that with the XML Serializer, I
EA> had no problem.I verified that I had correct well
EA> formed output from the transformer to the HSSF
EA> Serializer.

EA> here is my pipline config:

EA>     <map:pipeline>
EA>             <map:match pattern="*.xls">
EA>                 <map:generate type="bean"/>
EA>                 <!--<map:act type="header">
EA>                                 <map:parameter name="Pragma"
value="no-cache" />>
EA>                                 <map:parameter
EA> name="Content-Disposition" value="attachment ;
filename={1}.xls" />>
EA>                                 <map:parameter name="mime-Type"
EA> value="application/" />
EA>                         </map:act>
EA>                         -->
EA>                         <map:transform type="xslt"
EA> src="context://styles/xml2xls.xsl"/>
EA>                         <map:serialize type="xls"/>
EA>                         <!--<map:serialize type="xml"/>-->
EA>             </map:match>             
EA>         <!-- end added XLS matcher here -->        
EA>         </map:pipeline>

EA> Have you an idea? I spent a lot of time on it and it's
EA> really frustrating not to have it work.Is it a coccon
EA> Bug?

EA> Thank you very much.

EA> Amine

EA> PS: I'm using cocoon2.1m2 and i can't change for later
EA> version, because of the struts-cocoon plugin.

Best regards,
Peter Velychko                   

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message