|
-
Mar 6th, 2012, 09:41 AM
#3
Lively Member
Re: Report Viewer - Simple Difficulty!
 Originally Posted by intraman
A really simple problem here but one that I can't see to get my head around.
I have an MS report created in VS as an embedded resource within my application. I have a form with a report viewer on it. To put it simply, how to do I get the blasted thing to display in the report viewer!
This is my code:
Code:
ReportViewer1.LocalReport.ReportPath = Application.StartupPath & "Report1.rdlc"
ReportViewer1.SetDisplayMode(Microsoft.Reporting.WinForms.DisplayMode.PrintLayout)
At runtime,the report viewer displays:
"An error occurred during local report processing. The report definition has not been specified. Could not find file."
I am confused on two counts as surely I should not need to give a file path name anyway as it is an embedded resource? This must be straightforward, any help would be great. PS: It doesn't contain any data at the moment just an image with some text.
Jord
You forgot to add a backslash before "Report1.rdlc" try "\Report1.rdlc" instead
Pat
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|