vb.net - Visual Studio 在使用 Crystal 报表时抛出 System.Runtime.InteropServices.COMException: 'Exception from HRESULT: 0x800A5023'
问题描述
我认为这是新错误因为我在 Google 中找不到 System.Runtime.InteropServices.COMException: 'Exception from HRESULT: 0x800A5023' key word
我的代码
Public Sub tampilkantiket()
AxCrystalReport1.SelectionFormula = "totex{{pemesanan.id_pemesanan}}='" & txtidpemesanan.Text & "'"
AxCrystalReport1.ReportFileName = "Tiket.rpt"
AxCrystalReport1.WindowState = Crystal.WindowStateConstants.crptMaximized
AxCrystalReport1.RetrieveDataFiles()
AxCrystalReport1.Action = 1
End Sub
解决方案
您可以尝试以下两种可行的解决方案。
- 检查您要引用的表/字段。的内容
AxCrystalReport1.SelectionFormula
可能有误。您需要确保它们是正确的。 - 检查用于在应用程序中生成报告的版本和控件。如果您可以避免 ActiveXs 进入 .net 控件,则应由对应于该版本或更高版本的控件生成由高于 8 的水晶版本创建的报告。
推荐阅读
- sql - 在 SQL 中使用 LISTAGG 函数会导致错误:结果大小超出 LISTAGG 限制
- reactjs - 不能在 API 请求中包含 React 的分页
- javascript - 如何使用节点/电子桌面应用程序从 API 中提取新数据?
- python-3.x - 将 BeautifulSoup 数据放入 Pandas 数据框 - 空白
- javascript - d3圆环图变换:translateY
- python - 中间的正则表达式忽略匹配
- php - PHPUnit:如何测试返回 void 的 Doctrine Repository 方法?
- swift - 有没有办法用内容偏移量初始化 UICollectionView?
- javascript - reveal.js:将反应组件导入幻灯片而没有跨源请求错误?
- python - 我怎样才能完成这个功能?