LocalReport set-up and publish
23-Feb-1212 Leave a comment
How do I … keep reports in a sub-directory
May be set in code or in ReportViewer control
Dim report as New LocalReport()
report.ReportPath = “Reports\ReportName.rdlc”
How do I … fix Local reports that work in Visual Studio not when published
The errors you may get include:
- An error occurred during local report processing copy
The report definition for report ‘..\some_path_to_report\<reportname>.rdlc’ has not been specified
Could not find file ‘C:\inetpub\wwwroot\some_path_to_report\tse.rdlc’.
When reports are added their default Build Action is Embedded Resource.
To fix this change to Content and choose a copy policy, probably Copy if Newer
How do I … use a report in a referenced project
Add the report as a “Linked” file ( Add existing item > Add as Link )(probably) at the same directory level as in the referenced project
Then on these linked files choose the necesary options as above