I try to add Asp.net Ajax to a web site, but when I add a ScriptManager to a page
I get the error
Error: 'top.document.documentElement' is null or not an object
whenever I click on a control in that page
(e.g.?a TextBox)
Any ideas of what I might have missed?
Hello,
I have the same problem and I don't understand what is the error. I have the ScriptManager in the MasterPage file and the rest of the pages are working correctly.
Any idea?
Anyone figure this out? I'm having the same problem and it started right after upgrading to the release version. We have a page hosted inside of an iframe that throws the errors, so I'm wondering if it's related to that somehow?
Appreciate any help anyone has on this.
this page in the frame is one outside the immediate domain? Do a search on iframe for the last two weeks or so there was several posts on this ...there is also a fix link posted for it - i do not have the link handy but it is in previous posts...
For any other person who cannot find the elusive 'iframe' reference that has the miracle answer heres my solution. When I loaded the page it was being loaded in an iframe. Because the iframe is now the parent, it is also considered the top. Try using the parent function to reference the immediate parent. I.E. 'parent.document.documentelement'.
I hope that keeps the next person from wanting to beat people who leave references like "oh yeah I saw that here somewhere, it has something to do with..." as an answer to a question.
Im using scriptmanger in asp.net and using the update panel to hold the contents to avoid postback of the page in gridview . Im getting the error top.document.documentElement is null or not an object. Plzz helpme cause i want to know whre can i make changes in ajax or make any addn to avoid getting this error .
I've been having this same issue and I finally tracked it down. I have several other javascript files in my project, one in particular tracks the mouse position for a floating div. I have several top/module level variables, two in particular are top & left. They are the root of the problem and they interfer with the MicrosoftAjax.js file that is being served up by ScriptResource.axd.
Long story short, change your variable names from top and left, to something else like m_top, m_left (and don't forget to change it everywhere in your code). Variable naming just got a whole lot trickier now that we need to worry about outside scripts and not just our own.
No comments:
Post a Comment