打印到pdf [英] printing to pdf
问题描述
将报告直接保存为pdf文件,只需点击一下按钮即可。
不幸的是,报告工具组件没有pdf导出功能。
。有没有办法使用第三方组件来编程地执行此功能。
打印应该是静默的,以便不要求用户输入文件名。报告1点击将会制作一个名为c:\1.pdf的文件。
这样的东西
ActivatePdfPrinter(c:\1.pdf);
printreport;
ClosePdfPrinter;
或任何其他方法。
我使用delphi,但如果你建议任何其他
免费的开放源代码 PDFCreator 可以用作虚拟打印机,但也可以通过COM使用。默认设置甚至包括COM示例。
您可以在此处查看SourceForge SVN存储库中的COM示例: http://pdfcreator.svn.sourceforge.net/viewvc/pdfcreator/trunk/COM/
Delphi和ActiveX相处得很好,所以你不应该有太多麻烦。
The existing system has many reports . Using a free pdf printer like dopdf or cutepdf the user can open the report , choose the pdf printer , type in the filename and save the report as a pdf file.This seems a bit tedious
It would be nice to have the report directly saved as a pdf file just on click of a button. Unfortunately the reporting tool component doesnt have pdf export functionality. . Is there a way to programatically do this function using a third party component.
The printing should be silent , so that the user is not asked for a filename.Report 1 when clicked will make a file called c:\1.pdf for example. something like this ActivatePdfPrinter(c:\1.pdf); printreport; ClosePdfPrinter;
or any other method .
I use delphi but if you suggest any other tools that work in other programming languages then I can search in the right direction.
The free, open source PDFCreator can function as a virtual printer but it's also usable via COM. The default setup even includes COM examples.
You can check the COM samples in the SourceForge SVN repository right here: http://pdfcreator.svn.sourceforge.net/viewvc/pdfcreator/trunk/COM/
Delphi and ActiveX get along superbly so you should not have much trouble.
这篇关于打印到pdf的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!