Home > other >  Update Panel in ContentPage button Click not updating repeater in MasterPage
Update Panel in ContentPage button Click not updating repeater in MasterPage

Time:09-19

I have an update panel inside contentpage when I click the button in there, I'm checking on breakpoint running this code block but its not refresing the masterpages controls. still empty repeater and also label. After that I try f5 on browser then updating.

 var master = Master as mpage;
        if (master != null)
        {
            master.function();  // here the function databinding repeater inside masterpage
            var rp= (Repeater)Master.FindControl("repeaterInMasterPage");
             
            rp.DataBind();
        }

but not refreshing the repeater in masterpage and also label control in masterpage.

Best Regards

CodePudding user response:

I solved my problem via trying alternative ways.

Just need put the controls in a updatepanel on masterpage. and call update function of the udpatepanel in content page codebehind.

  • Related