在 ASP.Net 中将报告打印为 PDF 的最佳方法是什么?

发布于 2024-08-23 07:01:01 字数 73 浏览 4 评论 0原文

我有一个复杂的报告,我需要使用 GDI+(我不知道更好的方法)绘制多个页面并将其保存为 PDF 以便用户可以下载。最好的方法是什么?

I have a complicated report that I need to draw with GDI+ (I don't know of a better way) with multiple pages and have it save to PDF so the user can download. What is the best way to do this?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

貪欢 2024-08-30 07:01:01

不确定您的报告有多复杂以及您使用 GDI+ 做什么,但这里有一些可能有帮助的想法:

查看 ITextSharp 和/或 PDFSharp

spark 视图引擎 还具有内置 pdf 生成功能。

另一种想法....如果您有权访问 SQL 报告服务器和/或至少它的客户端,并且可以使用它来创建报告,您可以从 .Net MVC 生成和调用并输出为 PDF。

看看这个答案:
Asp.Net MVC 如何获取视图生成 PDF< /a>

Not sure how complex your report is and what you are doing with GDI+ but here's some ideas that may help:

Checkout ITextSharp and/or PDFSharp.

The spark view engine also has pdf generation built in.

As another thought.... If you have access to SQL Report server and/or at least it's client and can use it to create your report you can generate and call from .Net MVC and output as PDF.

Check out this SO answer:
Asp.Net MVC how to get view to generate PDF

我不在是我 2024-08-30 07:01:01

还有另一种方法,在服务器上安装 Bullzip ,并使用 COM 接口,可以通过编程方式打印我认为这会更省事...只需选择 Bullzip PDF 打印机作为活动打印机并将其打印到目标 pdf 文件夹即可。请查看此处,了解 COM 的工作原理。 .COM接口与bioPDF的COM模型相同。

希望这有帮助,
此致,
汤姆.

There is another way of doing it, install Bullzip on the server, and using the COM interface, you can programmatically print it out to a pdf document which I would think would be less hassle...simply select the Bullzip PDF Printer as the active printer and print it out to a destination pdf folder. Have a look at this here to see how the COM works...the COM interface is the same as bioPDF's COM model.

Hope this helps,
Best regards,
Tom.

雪花飘飘的天空 2024-08-30 07:01:01

我本人是 Data Dynamics ActiveReports 的粉丝。可能与他们是城里本地人有关,如果我有问题,我可以给他们打电话。不过,非常好的报告引擎。直接打印为 PDF。

I'm a fan of Data Dynamics ActiveReports myself. Probably has a little do with the fact that they're local in town, and if I have a problem I can just call them up. Very good reporting engine though. Prints directly to PDF.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文