来自HRESULT的异常:执行晶体报告时为0x800A5077

|| 我收到错误
0x800A5077
,我尝试导入
CrystalActiveXReportViewerLib10
CrystalReportsCommonObjectModelLib
,但仍然没有用。
Call ReportConnection(CInspAuditList, \"Pab_Prod\")
        CInspAuditList.ReportFileName = My.Application.Info.DirectoryPath & \"\\MAuditList.rpt\"
        Call SubReportConnection(CInspAuditList, \"Pab_Prod\")
        CInspAuditList.set_ParameterFields(0, \"mchno; \" & frmMachine.machine & \" ;true\")
        CInspAuditList.set_ParameterFields(1, \"batch; \" & CDbl(frmMachine.batch) - 1 & \" ;true\")
        CInspAuditList.set_ParameterFields(2, \"Points; \" & InpStdPt & \" ;true\")
        CInspAuditList.set_ParameterFields(3, \"ovrpt; \" & OvrPoints & \" ;true\")
        CInspAuditList.Action = 1
CInspAuditList.Action = 1
时发生错误 vb.net帮我申报
CInspAuditList as AxCrystal.AxCrystalReport
这是我的连接功能:
Public Function ReportConnection(ByRef CrystalReport1 As AxCrystal.AxCrystalReport, ByRef dsnname As String) As Boolean
        CrystalReport1.Connect = \"dsn=\" & dsnname & \";UID=\" & gstrID & \";PWD=\" & gstrPassword & \";DSQ=\"
    End Function
我想知道导致错误发生的原因以及我的连接是否正确     
已邀请:
        这发生在我身上,这是因为报告文件(.rpt)包含与数据库的连接,该连接不存在或无法由运行程序解决方案的计算机定位:打开报告文件(.rpt) ,菜单数据库,验证数据库,签出连接参数(我的是sql连接),确定,然后您会看到一条消息,说数据库是最新的,确定,将更改保存在报告中     

要回复问题请先登录注册