如何:打印可滚动表单(Visual Basic) [英] How to: Print a Scrollable Form (Visual Basic)

查看:88
本文介绍了如何:打印可滚动表单(Visual Basic)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用以下代码来打印可滚动的Windows窗体.但出现错误或我和Powerpacks ........

printForm1.Print(Me,PowerPacks.Printing.PrintForm.PrintOption.Scrollable);

在这方面的任何帮助将不胜感激. -对于C#,它是this.

同样,默认情况下,VB Powerpack也不安装到C#应用程序中.将"microsoft.VisualBasic"程序集添加到您的引用中,然后应获取它们.

但是,我强烈建议您不要使用PrintForm组件:使用一个(非Power Pack) ^ ]代替.它使用起来有点复杂,但是它要灵活得多,并且可以提供更好得多的打印输出.


I am using the following code to print a scroll able windows form. but got the error or Me and Powerpacks........

printForm1.Print(Me, PowerPacks.Printing.PrintForm.PrintOption.Scrollable);

any help in this regard will be highly appreciated.

解决方案

Assuming this is indeed C# as you tag says, then that would explain both: Me only exists in VB - for C# it is this.

Similarly, the VB Powerpacks are not installed by default to C# applications. Add the "microsoft.VisualBasic" assemblies to your references, and you should get them.

However, I would strongly suggest that the PrintForm component is not the way to go: use a (Non-power pack) PrintDocument[^] instead. It is a little more complex to use, but it is a lot more flexible and will give a much, much better printed output.


这篇关于如何:打印可滚动表单(Visual Basic)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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