Getting error in IE11 for javascript array

北慕城南 提交于 2020-01-15 03:41:20

问题


I get this error below only in IE edge. It works in all other browser apart from this one. I want to figure out what is causing this error:


Code rather than screenshot:

var ui_tabsets = new Array();

Causing error:

Object doesn't support this action.


回答1:


The error is that the Array constructor cannot be found.. This means something has gone wrong elsewhere. Perhaps you've closed an iframe this was running on or something that's lost you your HttpContext, more often this issue manifests with the error Can't execute code from a freed script. Webkit browsers will create you a new HttpContext if you try to call a function outside of a context and doesn't destroy contexts as eagerly as IE does so this issue probably won't occur in those browsers.

To find out where the problem is, create watches for Array in the debugger and step through the code leading up to this line, at some point you'll notice Array has gone. Work out how/why that line of code is releasing your context.



来源:https://stackoverflow.com/questions/35153417/getting-error-in-ie11-for-javascript-array

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!