PrintOutEx互操作方法将提高宏执行速度

时间:2019-12-24 12:13:41

标签: c# excel office-interop excel-interop

我的应用程序中有一个“打印”选项,可以将选定的纸张打印到打印机上。该应用程序已与excel集成在一起,并具有许多宏。

我看到执行打印操作时,可以看到宏性能正在提高。达到下面的线后,性能会提高

Application.ActiveWindow.Selectedsheet.PrintoutEx(Type.Missing, Type.Missing,1,Type.Missing,Printer)

宏包含一组代码。下面是一个示例片段

Range(9:20).Select
Selection.EntireRow.Hidden=True
Range("Copydata").Select
Selection.PasteSpecial Paste :=xlpasteAll, Operation :=xlNone, SkipBlank := False, Transpose := False

我们可以获取PrintOutEX的源代码以查看其确切功能吗?谁能说出它的作用

0 个答案:

没有答案
相关问题