VB兼容问题

window7 64位无法显示打印窗问题

在Windows7 64位和VS2008环境下,PrintDialog.ShowDialog不能显示打印对话框

在VS2008中编写?如下代码:

PrintDialog printDialog = new PrintDialog();
printDialog.ShowDialog();
在??XP环境下,它可以正常显示出打印对话框。但在Windows 7 64位环境下,什么也显示不出来,也没有异常抛出。

将PrintDialog.?UseEXDialog属性设置为True,可显示出打印对话框。代码如下:

PrintDialog printDialog = new PrintDialog();
printDialog.UseEXDialog = true;
printDialog.ShowDialog();

这是VS2008的bug,并且此bug可能不会在VS2008上被修复。
原文地址:https://www.cnblogs.com/slmdr9/p/5336503.html