I'm setting up my first test of using Reportviewer. All the application does is grab some data from a database, load it into a dataset and they populate a simple report with the datatable. The problem is when the report displays, it keeps displaying the message "Report Being Generated" and redisplaying the report. Its flashing about once a second. I've looked through all the viewer propertys and I don't see anything out of line.
The "Report is Being Generated" message is displayed when the report viewer is first processing the report. It's not completely clear from your description what is happening, but I wonder if you are performing an operation in your page during each postback that is causing the viewer to treat the report definition as having changed and therefore restart report processing each time. Are you setting any properties on the viewer after the LoadViewState event, such as during OnLoad? Doing so might cause the viewer to think the definition is changing and therefore abort the previous rendering and start a new one, with a new instance of the wait message. You might consider moving such code to OnInit.
Additionally, which version of the ReportViewer are you using? I'm assuming you are using the ASP.Net version of the control and not the winforms version.
- Navržen jako odpověď Seamus 26. ledna 2011 11:37
For me, I had the same issue and the problem was simply that I was setting up custom credentials on Page_Load. When the report has no parameters there's a postback and the credentials we being set again and so it started to render the report again resulting in a constant refresh.
I moved the code to OnInit and that resolved the issue.
Also, if the report had parameters, the symptoms were different. In this case, the report body did not render at all and the parameter toolbar would refresh with the parameter value missing.
Again, moving code that modifies the report viewer control out of the Page_Load resolved the issue.
I also had the same problem. However, mine was caused by another issue.
I tried moving the code from Load and that did not help.
What ended up solving my refresh issue (mentioned by user Arshika) was the Property AutoRefresh in my .rdlc file. AutoRefresh was set to 1, which automatically refreshes the report every second when rendered in HTML. I set this property to 0 and it no longer AutoRefreshed.
- Upravený DKelley66 29. února 2012 17:12
I just solve this $#it putting the method in the pageload using a if ! ispostback verification.
My gosh, reportviewer on vs2012 is the worst ever made. Just going back to 2005/2008.
Someday visit my blog about c#.
This is so weird! it happens on the client side but your solution works.
Anyways I am glad it worked. Thank You!
MCITP: Business Intelligence Developer 2008, MCITP: Database Developer 2008, MCITP: Database Administrator 2008, MCPD: Enterprise Application Developer 3.5, MCTS: SharePoint 2010, Configuration Charter Member, MCTS: .NET Framework 3.5, Windows Workflow Foundation Applications, MCTS: Microsoft Windows Vista: Configuration, Microsoft® Certified Trainer 2010