在HP打印机上C#打印成功,但在Dot Matrix上不成功 [英] C# printing is successfull on HP Printer but not on Dot Matrix

查看:118
本文介绍了在HP打印机上C#打印成功,但在Dot Matrix上不成功的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



专家,我已经用C#开发了一个应用程序,它是通过HP打印机而不是通过点矩阵打印机来打印水晶报表.

代码是否有问题...?还是其他?...?

没有异常或错误.

请帮帮我.

代码是:

Hi,

Experts,I have developed an application in C#,it is printing a crystal report through HP printer but not through the Dot Matrix Printer.

Is there any problem with the code...? Or is it something else....?

No exception or error is raised.

Please Help me.

The code is :

rptTML.Database.Tables[0].SetDataSource(g_DT);
rptTML.PrintToPrinter(1, false, 1, 1);

推荐答案

如果您的打印机具有要安装的驱动程序,则可以使用普通的Windows打印系统.大多数打印机(包括POS打印机)都具有可用的Windows驱动程序. (无论如何,大多数点矩阵打印机都是与Epson兼容的.)某些POS打印机驱动程序也允许直接将转义码发送到打印机(使用特殊字体).可能您不需要这种功能.

如果不是这种情况,则可以在添加打印机向导"的帮助下添加通用/纯文本"打印机(驱动程序).完成后,您可以为其配置某些命令(转义序列)-字体大小10/12/17,粗体打开/关闭,下划线打开/关闭,作业开始/停止,进纸和尺寸选择.
If your printer has driver to install, then you can use normal Windows print system. Most printers, including POS ones, have working Windows drivers available. (Most dot-matrix printers are Epson compatible anyway.) Some POS printer drivers allow send escape codes directly to printer too (using special fonts); probably you don''t need such functionality.

If this is not the case, then you can add Generic/Text Only printer (driver) with help of Add Printer Wizard. Once done, you can configure certain commands (escape sequences) for it - Font size 10/12/17, Bold on/off, Underline on/off, job start/stop, paper feed and size select.


这篇关于在HP打印机上C#打印成功,但在Dot Matrix上不成功的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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