C#打印pdf文件时出现System.Drawing.Printing问题. [英] C# printing pdf file with System.Drawing.Printing problem.

查看:852
本文介绍了C#打印pdf文件时出现System.Drawing.Printing问题.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

 Hi,

 Hi,

我可以打印文本文件,但不能打印pdf文件.请帮帮我.

 I am able to print a text file, but I am not able to print a pdf file. Please help me.

 私有System.ComponentModel.Container组件;

私有System.Windows.Forms.Button printButton;

  私有字体printFont;

推荐答案

您好,

根据您的描述,如果要使用C#打印PDF文件,可以参考以下链接:
http://social.msdn.microsoft.com/论坛/en-us/netfxbcl/thread/3EF19BEA-66A5-4DC5-BDBE-B59B86B38E3D

Based on your description, if you want to print PDF file in C#, you can refer to this link:
http://social.msdn.microsoft.com/forums/en-us/netfxbcl/thread/3EF19BEA-66A5-4DC5-BDBE-B59B86B38E3D

我也建议您使用PDFSharp dll.这是dll的第三部分,其中包含许多处理PDF文件的方法.

Also I suggest you to use the PDFSharp dll. It is the third part dll which contains many methods to manipulate PDF file.

这是PDFSharp主页的链接,您可以下载并参考其中的dll:
http://www.pdfsharp.net/?AspxAutoDetectCookieSupport=1

Here is a link about the homepage of PDFSharp, you can dowaload and refer to the dll there :
http://www.pdfsharp.net/?AspxAutoDetectCookieSupport=1

以下是使用PDFSharp dll tp打印PDF文件的链接:
http://www.pdfsharp.net/wiki/PrintPdfFile-sample.ashx

Here is a link to use the PDFSharp dll tp print PDF file:
http://www.pdfsharp.net/wiki/PrintPdfFile-sample.ashx

由于它是第三方产品,因此Microsoft不支持.因此,如果您对此有任何疑问,可以向PDFSharp支持网站寻求帮助:
http://www.pdfsharp.net/Support.ashx

As it is the third part product, Microsoft donen't support that. So if you have any problem about that you can turn to PDFSharp support website for help:
http://www.pdfsharp.net/Support.ashx

谢谢.

此响应包含对第三方万维网的引用地点. Microsoft为方便您而提供此信息. Microsoft不控制这些站点 并且未测试在这些站点上找到的任何软件或信息;因此,Microsoft无法对在此找到的任何软件或信息的质量,安全性或适用性做出任何陈述.使用任何物品都有内在的危险 在Internet上找到的软件,Microsoft提醒您在从Internet上检索任何软件之前,请确保您完全了解风险.

This response contains a reference to a third party World Wide Web site. Microsoft is providing this information as a convenience to you. Microsoft does not control these sites and has not tested any software or information found on these sites; therefore, Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. There are inherent dangers in the use of any software found on the Internet, and Microsoft cautions you to make sure that you completely understand the risk before retrieving any software from the Internet.


这篇关于C#打印pdf文件时出现System.Drawing.Printing问题.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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