Skip to Content
0
Jun 30 at 03:07 PM

Crystal 2016 Subreports

81 Views

Crystal Reports 2016

Getting error "Invalid report file path" when setting .OpenSubreport(sSubReportName). The path is correct and is set to a logical drive. All other reports open from the same path.

oReportFile.Load(sRptFilename)

RptFormulaFieldDefinitions = oReportFile.DataDefinition.FormulaFields

oReportFile.SetDataSource(ReportData)

frmReportViewer.CRViewer.ReportSource = oReportFile

If sRptFileCopy <> "" Then oReportFileCopy.Load(sRptFileCopy)

RptFormulaFieldDefinitionsCopy = oReportFileCopy.DataDefinition.FormulaFields

End If

oReportFileSub.OpenSubreport(sSubReportName)

oReportFileSub.SetDataSource(ReportDataSub)

If sRptFileCopy <> "" Then

oReportFileCopy.SetDataSource(ReportData)

End If