本文介绍了rdlc打印不带预览的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想在没有打印对话框的情况下打印报表查看器,对她没有帮助
I want to print report viewer without print dialog any help her
推荐答案
PrintDocument1 = new PrintDocument();
PrintDocument1.DocumentName = "MyPrint";
PrintDocument1.PrinterSettings = ps;
StandardPrintController silentController = new StandardPrintController();
PrintDocument1.PrintController = silentController;
PrintDocument1.DefaultPageSettings.Margins.Top = 20;
PrintDocument1.DefaultPageSettings.Margins.Left = 20;
PrintDocument1.DefaultPageSettings.Margins.Right = 20;
PrintDocument1.DefaultPageSettings.Margins.Bottom = 20;
PrintDocument1.Print();
这篇关于rdlc打印不带预览的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!