10

在 Visual Studio 2005 中,如何在打印预览模式下直接在 ReportViewer 控件中显示报表?

4

2 回答 2

25

使用SetDisplayMode()方法:

MyReportViewer.SetDisplayMode(DisplayMode.PrintLayout);
于 2009-02-16T11:50:39.413 回答
0

在 Windows 窗体应用程序中,如果您在 reportviewer 的 RenderingComplete 事件中调用 SetDisplayMode 方法,可能会导致 StackOverflowException。调用该方法的位置不正确。

于 2015-05-27T02:44:32.280 回答