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

Dynamically load an ASPX page to a pageView on Client Site

3 Answers 165 Views
TabStrip
This is a migrated thread and some comments may be shown as answers.
Bryan Tan
Top achievements
Rank 1
Bryan Tan asked on 06 Apr 2010, 08:26 AM
Hi all,

I wish to load the ASPX file to the pageview on the client site. Can anybody show me the example?

Thanks.

Regards,
Bryan Tan

3 Answers, 1 is accepted

Sort by
0
Princy
Top achievements
Rank 2
answered on 08 Apr 2010, 11:15 AM
Hello Bryan Tan ,

One suggestion would be placing IFRAME element in pageview and setting the src accordingly from client code. Here is the code that I tried for achieving the same.

aspx:
 
<telerik:RadMultiPage runat="server" ID="RadMultiPage1"
    <telerik:RadPageView ID="RadPageView1" runat="server" Width="100%"
        PageView 
        <iframe id="iframe1" frameborder="0" width="700" height="550"></iframe> 
    </telerik:RadPageView> 
</telerik:RadMultiPage> 

javascript:
 
<script type="text/javascript"
    function changeURL() { 
        var MultiPage = $find("<%=RadMultiPage1.ClientID %>"); 
        var pageView1 = MultiPage.findPageViewByID("RadPageView1"); 
        pageView1.select(); 
        var str = document.getElementById("iframe1"); 
        str.src = "http://www.google.com"
    } 
</script> 

Thanks,
Princy.
0
Henry Cordova
Top achievements
Rank 1
answered on 12 May 2011, 11:22 PM
Hi Princy, the example works perfectly.

Is possible show the wait effect while the page loads in the iframe?
0
Veronica
Telerik team
answered on 13 May 2011, 09:49 AM
Hi Henry Cordova,

Other possible solution to add pages in the PageView is to use the ContentUrl property added in Q3 2010 (version 2010.3.1109). Also you can display a loading animation while an external page is loading in a RadPageView. Please take a look at this Code Library for an example.

Best wishes,
Veronica Milcheva
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get now >>

Tags
TabStrip
Asked by
Bryan Tan
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Henry Cordova
Top achievements
Rank 1
Veronica
Telerik team
Share this question
or