Click here to Skip to main content
15,921,841 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Page structure is like

XML
<asp:Panel ID="pnlResultSet" runat="server">
        <asp:UpdatePanel ID="uplrepeter" runat="server" UpdateMode="Always">
            <ContentTemplate>
                <uc1:PostBackPager ID="PostBackPager2" runat="server" OnNextPageChanged="NextChanged"
                                            OnPreviousPageChanged="PreviousChanged" OnPageChanged="PageChanged" />
                <%--Some Code will be here--%>
                <%--The control "PostBackPager" is for paging for the above portion.
                Now When I click on Page 2 of the usercontrol PostBackPager1
                it changes to page 2 but PostBackPager2 remains its initial state
                and the same is happening for vice versa.--%>
                <uc1:PostBackPager ID="PostBackPager1" runat="server" OnNextPageChanged="NextChanged"
                                            OnPreviousPageChanged="PreviousChanged" OnPageChanged="PageChanged" />
            </ContentTemplate>
        </asp:UpdatePanel>
    </asp:Panel>


Now the problem is:

The control "PostBackPager" is for paging for the above portion. Now When I click on Page 2 of the usercontrol PostBackPager1 it changes to page 2 but PostBackPager2 remains its initial state and the same is happening for vice versa.

Thanks in advance..
Posted

1 solution

You have to understand that though they are two same usercontrol but when they are rendered all the controls inside them have totally different name and ID's. Making some change in first UC would not make any change in second UC until you write for it. Since both are in same Update Panel, this should not be an issue. Juse sync (using code on server side) the other one based on the triggered UC - once done, it will reflect back.
 
Share this answer
 
Comments
arindamrudra 16-Sep-10 0:17am    
Reason for my vote of 5
Automatic vote of 5 for accepting answer.
arindamrudra 16-Sep-10 0:18am    
Thank you very much... I am going to try in that way now.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900