Microsoft JScript运行时错误:“未定义"为null或不是对象 [英] Microsoft JScript runtime error: 'undefined' is null or not an object

查看:337
本文介绍了Microsoft JScript运行时错误:“未定义"为null或不是对象的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的项目中,我使用了一些Java Flash脚本和其他一些应用程序.
当我运行我的项目时,发生以下错误.
| Microsoft JScript运行时错误:未定义"为null或不是对象|

之后,闪光灯不起作用.

In my project i used some Javascripts for flash and some other application.
When i run my project the following error was occurred.
|Microsoft JScript runtime error: ''undefined'' is null or not an object|

After that The flash did not work.

推荐答案

您的问题非常模糊,缺少详细信息.但是在检查undefined时,您可能只是缺少了=.否则,请添加更多信息以及发生错误的实际代码.

http://www.w3schools.com/jsref/jsref_undefined.asp [
Your question is very vague and missing detail information. But you might just be missing an = when checking undefined. Otherwise, add more info and the actual code where the error occurs.

http://www.w3schools.com/jsref/jsref_undefined.asp[^]

Good luck!


通用答案是如果您尝试使用一个为null的对象,则可能发生此错误."

通常,在使用对象时,一种更好的做法是检查对象的可为空性,以免出现此类意外情况.
同样,围绕任何关键功能的try-catch块也将停止在浏览器上显示的难看错误.有关更多详细信息,请检查
www.w3schools.com/js/js_errors.asp [
Generic answer would be "this error can occur if you are trying to use an object which is null."

In general, when you are using an object, its a better practice to check object for nullability to avoid such surprises.
Also a try-catch block surrounding any critical functionality would also stop ugly errors showing up on browser. For more details check www.w3schools.com/js/js_errors.asp[^]

Please provide code snippet where this error is occuring then we might be able to give you pin-point answer.

Hope that helps
Milind


这篇关于Microsoft JScript运行时错误:“未定义"为null或不是对象的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆