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

Javascript error when hovering after postback

2 Answers 70 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Chet
Top achievements
Rank 1
Chet asked on 12 Oct 2011, 02:52 PM
When I make a change to the schedule, or if I view the AdvancedEditForm for a particular appointment, I start getting the following error when I hover over an appointment:

Unable to get value of the property 'get_allowDelete': object is null or undefined

If I add a new appointment the page refreshes (via Ajax, not a full postback).  I can hover over the new appointment without a problem, but any existing appointments will throw this error.

When I step through the JavaScript debugger, I see that there is a call to get_element(), and this method looks in the first position of the _domElements array.  In my case, the first entry is null, but the second contains the element that it should be returning.

2 Answers, 1 is accepted

Sort by
0
Ivana
Telerik team
answered on 14 Oct 2011, 05:02 PM
Hello Chet,

I did not manage to reproduce the described behavior. I tested the get_allowDelete() and get_allowEdit() methods of the appointment client-side object and everything worked as expected.

Could you please provide me with some more information about the issue in question? You could send us a support ticket with a sample page illustrating the issue attached to it, so we will be able to troubleshoot that kind of a behavior locally. 

Thank you in advance.

Regards,
Ivana
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
0
Chet
Top achievements
Rank 1
answered on 14 Oct 2011, 06:01 PM
Sorry, I thought I had closed this question.

I had a custom ScheduleProvider which was caching the appointment objects.  After a more careful examination of XmlScheduleProvider, I noticed that new Appointment objects need to be created every time GetAppointments is called.  If you don't do this, the AppointmentControls collection fills up with out-of-date entries which cause get_allowDelete to break.
Tags
Scheduler
Asked by
Chet
Top achievements
Rank 1
Answers by
Ivana
Telerik team
Chet
Top achievements
Rank 1
Share this question
or