I have a few RDLC files in my WPF application. When I publish the project, the report files don't get published, and when I try to access them with the client I get an error saying that they're not found. I've checked the publish folder, and indeed, they're not there. I call the RDLC files with the following code:
Microsoft.Reporting.WinForms.ReportViewer rvReportViewer;
/* ... */
rvReportViewer.LocalReport.ReportPath = string.Format("Reports/{0}.rdlc", ReportName);
I've tried setting the Build Action on these to "Resource", which is what I have for my static image files, but that doesn't seem to make any difference.
Why don't the reports get copied to the publish directory? Is there a way to force this to happen, or should I be accessing them in some other way?
Thanks!