Glenn,

Don't know if this is any good to you, but here's an excerpt from one
I've just finished:
....
FacesContext context = FacesContext.getCurrentInstance();  
HttpServletResponse response = (HttpServletResponse)    
         context.getExternalContext().getResponse();    
response.setContentType( "application/pdf" );                    
response.setHeader(
  "Content-disposition",
  "attachment;filename=AnnualReport_"+model.getYear()+".pdf");

OutputStream out = response.getOutputStream();
reporter.writeReport( out );
FacesContext.getCurrentInstance().responseComplete();
....

where the reporter is a little class that wraps the Jasper reports code.

Graham

> All,
>  I am looking at Jasper reports but I am unsure the best way to
> integrate Jasper Reports into a My Faces Application. Any help would
> be greatly appreciated. If you are able to help and you come to NYC at
> any time, the beer is on me!
>  
> Thanks
>  
> Glenn
> 
> 
>          
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam? Yahoo! Mail has the best spam protection around 
> http://mail.yahoo.com 
-- 
Graham Stark, Virtual Worlds
phone: (+044) 01908 618239 mobile: 07952 633185
Homepage http://www.virtual-worlds.biz/people/graham_s
Virtual Chancellor http://www.virtual-worlds.biz/vwc     

Reply via email to