本文介绍了c#使用rdlc打印文档的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用以下代码....用于打印文档

i am using below code.... for print a document

PrintDocument printDoc = new PrintDocument();
            printDoc.PrinterSettings.PrinterName = printerName;
            if (!printDoc.PrinterSettings.IsValid)
            {
                string msg = String.Format("Can't find printer \"{0}\".", printerName);
                Console.WriteLine(msg);
                return;
            }



和错误是.printersettings不在intellisense





我的错误显示如下...



''XXXXXXX.PrintDocument''不包含''PrinterSettings''的定义,也没有扩展名方法''PrinterSettings''接受类型为''XXXXXXX.PrintDocument''的第一个参数可以找到(你是否错过了使用指令或汇编参考?





你可以帮我???


and error is ".printersettings" not in intellisense


my error is shown like this...

''XXXXXXX.PrintDocument'' does not contain a definition for ''PrinterSettings'' and no extension method ''PrinterSettings'' accepting a first argument of type ''XXXXXXX.PrintDocument'' could be found (are you missing a using directive or an assembly reference?


can u help me???

推荐答案



这篇关于c#使用rdlc打印文档的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-23 09:17