空引用异常发生 [英] Null Reference Exception occured

查看:111
本文介绍了空引用异常发生的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,

我收到主题错误,但我不明白如何找到对象.

Hello,

I am receiving the subject error and I don''t understand how to find the object.

Dim sFile As String = Zone.ConfigPath



如果我在区域"中搜索到229个匹配项,那么找到正确位置的最快方法是什么?

再次感谢,我错过了这个网站.



If I search Zone I get 229 matches, what is the quickest method to find the right place?

Thanks once again, I missed this website.

推荐答案

如果上面的行导致了问题,请使用调试器,查看Zone是否为空.如果这是原因,那么您将必须找出为什么未在先前的代码中对其进行初始化.
If the line above is causing the problem, using debugger, see if Zone is nothing. If that is the cause, then you would have to find why it isn''t initialized in your earlier code.


这篇关于空引用异常发生的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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