I'm using the latest (2010) ReportViewer Web Control in an ASP.NET 4 project. My client wants me to suppress / hide the initial "Loading" message that gets displayed while the report is being fetched.
Yeah... I know... why hide information that tells you what's going on? But, the client wants what the client wants.
I know that if you use the report viewer control with AsyncRendering=False that you can then set the WaitControlDisplayAfter property to a ridiculously long value.
Unfortunately, I need to have AsyncRendering=True (showing multiple reports on a type of Dashboard thingy). This (according to MSDN http://msdn.microsoft.com/en-us/library/microsoft.reporting.webforms.reportviewer.waitcontroldisplayafter.aspx see Remarks section) will mean that the "Wait Control" will always show. (Grr-r-rr!)
So the question is, how to I not show this control using async rendering?
(An aside question the client asked me, was that they wanted to see a cached copy of the report while it's loading an updated one - any takers on this one?)
Thanks, Jaans
I found a way to hide the loading message by manipulating the DOM with jQuery. Adding the following script to the page with the reportviewer did the trick:
<script type="text/javascript">
$(function () {
var waitMsg = $("div[id$='AsyncWait_Wait']");
waitMsg.wrap("<div style='display:none; visibility: hidden'></div>");
});
</script>
Starting from Joe Camp's answer, the following works for me. I added this entry to the application's CSS file:
div[id$='AsyncWait_Wait']
{
display: none !important;
visibility: hidden !important;
}
Tested working in IE8, IE9, Chrome 21, FF10, FF15, and Safari (version 5-ish, iPad3 iOS 5.1.1).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With