Avatar of dejaanbu
Flag for Oman asked on

Refreshing Asp:Calendar on MasterPage

Hello All,

I have a asp:calendar control which is inside an updatepanel on the masterpage. In content page, i have the interface for adding /deleting/changing events. these changes should be reflected in the asp:calendar located on masterpage.   the functionalities in contentpage are handled in Javascript, so i am calling

__doPostBack('Themasterpage updatepanel's uniqueid' , '')  once event is added/deleted/changed in contentpage.

when i trace, it fires Calendar's Dayrender event, but the calendar shows old data . If i add another event and then trace, then the Calendar shows the previously added event correctly but not showing secondly added event and so on.

(each second time, the calendar shows previously added new event).

i have tried ClientId instead of uniqueId  , - > the same results

also tried having a hidden button on masterpage, and on click of that, calling, updatepanel's update method , instead of dopostback, called document.getelementbyid('btn.clientid').click()  -> the same results come

anyone can suggest what is wrong here?

Any help is greatly appreciated!
ASP.NET.NET Programming

Avatar of undefined
Last Comment

8/22/2022 - Mon
Kamal Khaleefa

in code behind of your content page
try to find the control of the calendar and try to set it

   Dim x As Calendar= Me.Page.Master.FindControl("calender id")
then set x to ur value


i am able to get the referrence of the calendar in masterpage. the problem is Calendar's Day render method should fire and re-draw the calendar.

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question

Solved myself
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck