I am using Visual Studio Express 2012, I am trying to invoke my deployed reports using winforms, this is what i did.
- I created a new c# winforms application
- I went to the toolbox to look for the
ReportViewer
control(but it wasnt there)
2.1 So i added it manually by rightclicking Toolbox > Choose Items > then i selected the report viewer
- After that i dragged and dropped it on the form(but it goes straight to the bottom tray and doesn't give me any options)
I have seen many questions that address the same issue but with no solution.
The problem was
Microsoft.ReportViewer.WinForms
version 10, I am not sure why, but it was doing the same thing on my colleague's computer.Here is what I did:
Microsoft.ReportViewer.WinForms
version 11.0.0.0right clicked > Choose Items
Microsoft.ReportViewer.WinForms
version 10 and selected version 11.I tried the accepted answer but it didn't work to me.
So, another solution could be:
In your
Designer.cs
file, you have to add this line (manually):This is my example in a form called "FrmPreviewRpt1":
Here is a screenshot of the result:
The bad news with this approach is that you have to change the size (and possibly other visible attributes) in the Designer.cs file manually.