开发者

When debugging with firebug, no error

I declared global variable in js file which is filled after jquery.ajax call. Everything works fine when I put breakpoint to see if the global variable has its value with Firebug, I can see it, no problem. But when I remove breakpoint and try again, error with variable 'undefined' shows. 开发者_高级运维I also tried to put result into hidden field and then retreive its value later. Same error.

I don't know what is happening? With breakpoint set in Firebug it works fine, without it, shows 'undefined' error.

P.S. No postbacks are made in these processes.


The symptoms suggest it is a timing issue: when you set the breakpoint, the ajax call has time to 'return', but without it, you are executing code that depends on the ajax call, but it has not returned yet.

That's all I can think of, without having seen the code..

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜