RadMultiPage client-side pageview change after async postback

2 posts, 0 answers
  1. Pawel
    Pawel avatar
    8 posts
    Member since:
    Sep 2009

    Posted 09 May 2010 Link to this post

    Hi,
    I'm implementing a project where I'm changing the page views by java script. The RadMultiPage is contained withing an Update panel.
    The client side view change works ok until I do an asnychrounous postback with the enclosing update panel.

    Here is a code isolating the problem (in my project the page views are added dynamically which does not seem to be a problem here):

    <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication1.WebForm1" %> 
     
    <%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> 
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
    <html xmlns="http://www.w3.org/1999/xhtml"
    <head runat="server"
        <title></title
    </head> 
    <body> 
        <form id="form1" runat="server"
        <asp:ScriptManager ID="ScriptManager1" runat="server"
        </asp:ScriptManager> 
        <div> 
            <asp:UpdatePanel ID="UpdatePanel1" runat="server"
                <ContentTemplate> 
                    <input type="button" onclick="ChangePageView('view1');" value="view1" />&nbsp 
                    <input type="button" onclick="ChangePageView('view2');" value="view2" /> 
                    <telerik:RadMultiPage SelectedIndex="0" ID="RadMultiPage1" runat="server"
                        <telerik:RadPageView ID="view1" runat="server"
                            page1 
                        </telerik:RadPageView> 
                        <telerik:RadPageView ID="view2" runat="server"
                            page2 
                        </telerik:RadPageView> 
                    </telerik:RadMultiPage> 
                    <asp:Button ID="PostBackButton" runat="server" Text="DoPostBack" /> 
                </ContentTemplate> 
            </asp:UpdatePanel> 
        </div> 
        </form> 
     
        <script type="text/javascript"
            function ChangePageView(viewID) 
            { 
                var multiPage = $find("RadMultiPage1"); 
                var pageView = multiPage.findPageViewByID(viewID); 
                pageView.select(); 
            } 
        </script> 
    </body> 
    </html> 
    Kind regards,
    Pawel



  2. Pawel
    Pawel avatar
    8 posts
    Member since:
    Sep 2009

    Posted 11 May 2010 Link to this post

    I noticed that this seems to be fixed in Q1 SP1.

    regards
    Pawel
Back to Top