打印对话框不显示在 64 位计算机上的 Crystal Report Viewer 中 [英] Print Dialog Does not show up in Crystal Report Viewer on 64 bit machine
问题描述
我有一个运行 Windows 2008 Server 64 位的客户端.他正在运行我们的软件,它具有内置的水晶报表查看器功能.
I have a client, who is running Windows 2008 Server 64 bit. He is running our software, it has a built in crystal report viewer functionality.
无论如何,打印对话都不起作用.它适用于我们的 32 位盒子,我们对其进行了验证.我在我们的 64 位盒子上验证了它,打印对话框也没有打开.我在网上做了一些研究.一个建议是设置 m_printDlg.UseEXDialog = True.我试过了,但也没有用...
The print dialogue just wouldn't work no matter what. It worked on our 32 bit box and we verified it. I verified it on our 64 bit box, and the print dialogue didn't open either. I did some research online. And one suggestion is to set m_printDlg.UseEXDialog = True. I tried that, but that DID NOT WORK EITHER...
我现在有点沮丧.有没有人遇到过类似的问题?如果有,请告诉我.
I am kind of frustrated now. Has anyone encountered the similar issue? If so, please let me know.
这是代码片段.
#Region " Methods "
Public Overrides Sub PrintReport()
' NOTE: Do not use bug in reportviewer
'MyBase.PrintReport()
Dim objRpt As ReportDocument = CType(Me.ReportSource, ReportDocument)
If m_printDlg Is Nothing Then
m_printDlg = New PrintDialog
End If
m_printDlg.PrinterSettings = ReportEngine.GetPrinterSettings(objRpt)
m_printDlg.UseEXDialog = True
'm_printDlg.ShowDialog(Me)
If m_printDlg.ShowDialog = DialogResult.OK Then
ReportEngine.PrintReportDocument(objRpt, m_printDlg.PrinterSettings)
End If
End Sub
结束区域
推荐答案
尝试编译您的应用程序以针对任何或目标 x64(如果已经有),看看是否有任何效果.
Try compiling your application to target any or target x64 (if already any) and see if that has any effect.
这篇关于打印对话框不显示在 64 位计算机上的 Crystal Report Viewer 中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!