This is a migrated thread and some comments may be shown as answers.

Issue with ShowContentDuringLoad

4 Answers 128 Views
Window
This is a migrated thread and some comments may be shown as answers.
Joe
Top achievements
Rank 2
Joe asked on 21 Oct 2010, 04:34 PM
Hi,

I've added ShowContentDuringLoad="false" to my otherwise functional RadWindow (see below). Now the loading dialog is displayed but never goes away. I can see in Fiddler that the request completed successfully with a 200 response. Do you have any idea why this is happening? The window loads correctly if the ShowContentDuringLoad attribute is either set to true or removed.

Thanks,
Joe

--------------------------------
      <telerik:RadWindow ID="ViewRRDialog" runat="server" Title="View PDF Report"
        Height="550px" Width="800px" ReloadOnShow="true" Modal="true"
        Skin="WebBlue" VisibleStatusbar="false" ShowContentDuringLoad="false">

4 Answers, 1 is accepted

Sort by
0
Accepted
Georgi Tunev
Telerik team
answered on 22 Oct 2010, 05:46 AM
Hi Joe,

The title of the window leads me to believe that you are opening a PDF file in that RadWindow, am I right? If so, such behavior is expected - the PDF document is not a page and it doesn't fire window.onload that RadWindow expects before stopping the loading animation. If you are going to show PDF documents in the window, ShowContentDuringLoad should be set to true.

Greetings,
Georgi Tunev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Joe
Top achievements
Rank 2
answered on 22 Oct 2010, 06:36 PM
Hi Georgi,

You are correct; I am displaying a PDF in the RadWindow using the Adobe plug-in.

Thanks for the info. I will leave the value of ShowContentDuringLoad set to true.

Regards,
Joe
0
JARROD R
Top achievements
Rank 1
answered on 06 Jan 2014, 10:01 PM
I know this is an old thread, but we encountered the same issue.  We are opening a PDF in the RADWindow control. 

In firefox and chrome, the PDF opens without issue, right in the RAD Window, and the loading circle displays before it opens.  In IE though, the loading circle displays and never loads the PDF.  It just spins and spins.

We changed ShowContentDuringLoad to TRUE and the PDF then opens in IE without issues (firefox and chrome also still work correctly).

Was this always just an IE issue?

Is there a way to show the loading circle when ShowContentDuringLoad is set to TRUE?
0
Marin Bratanov
Telerik team
answered on 07 Jan 2014, 01:19 PM
Hi Jarrod,

This is an IE problem - the iframe's onload event will not fire when a PDF is loaded in it. This is the event used to remove the loading sign. If it does not fire there is no way to know when the content has been received.
You can easily confirm this by loading a simple pdf in an iframe under different browsers:
<iframe src="http://www.adobe.com/products/pdfjobready/pdfs/pdftraag.pdf" onload="alert(1);"></iframe>


What you can do is:
- keep ShowContentDuringLoad to true for cases when you open PDFs. This will make sure they are always seen
- try hiding the loading sign when the RadWindow shows only in IE, so that the rest of the browsers maintain the old behavior:
<telerik:RadWindow ID="RadWindow1" runat="server" OnClientShow="showContentForIE">
</telerik:RadWindow>
<script type="text/javascript">
    function showContentForIE(wnd) {
        if ($telerik.isIE)
            wnd.view.onUrlChanged();
    }
</script>

I cannot guarantee this will work as expected, so you should test it first to see if it has the desired behavior.

Regards,
Marin Bratanov
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
Tags
Window
Asked by
Joe
Top achievements
Rank 2
Answers by
Georgi Tunev
Telerik team
Joe
Top achievements
Rank 2
JARROD R
Top achievements
Rank 1
Marin Bratanov
Telerik team
Share this question
or