水晶PDF文件报告? [英] Crystal Reports in a PDF file?

查看:120
本文介绍了水晶PDF文件报告?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用下面的代码输出水晶报表到ASP.NET应用程序:

I am using the following code to output a Crystal Report to an ASP.NET application:

Dim rptDocument As New ReportDocument
Dim rptPath As String = Server.MapPath("Reports/Employees.rpt")

rptDocument.Load(rptPath)
Me.CrystalReportViewer1.ReportSource = rptDocument

一切工作正常。我的问题是,有没有办法呈现报表为PDF文件,而不是渲染到的CrystalReportViewer?

Everything is working fine. My question is, is there a way to render the report as a PDF file instead of rendering to a crystalreportviewer?

我使用Visual Studio 2008和Crystal Reports的Visual Studio 2008

I am using Visual Studio 2008 and Crystal Reports for Visual Studio 2008.

推荐答案

是的,你可以使用的ExportToHttpResponse 。设置 ExportFormatType 以PortableDocFormat。看看这个教程

Yes, you can use ExportToHttpResponse. Set the ExportFormatType to PortableDocFormat. Check out this tutorial.

这篇关于水晶PDF文件报告?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆