I ran into this issue today while working on my personal ASP.Net 2.0 project. I was getting the error when my callback function (client side) was running one of my custom javascript methods. I did a little googling and came across this post which didn't tell me about my problem specifically, but there were lots of comments about it:
And... does someone after this change gets som kind of bug , when calling method from server and gets "PendingCallbacks[...].async is empty or it is not an object" error on JavaScript Side?
My App still works, but i can not track this bug. Can anyone help?
It turns out that the issue is related to variable scoping in the ASP.Net client side functions:
Actually, if MS replaced the following script code WebForm_CallbackComplete:
for (i = 0; i < __pendingCallbacks.length; i++) {...}
with:
for (var i = 0; i < __pendingCallbacks.length; i++) {...}
("i" is now locally declared instead of the global scope)
.. that would solve most of our problems, I think.
Sure enough, this solved my problem. In my custom javascript method I had a for loop using a variable named “i“ so I was changing the value in the “i“ of Microsoft's code and causing the exception. So if you hit this issue, make sure you don't use “i“ and/or make sure your variables are properly scoped.