本文介绍了怎么了?你调用的对象是空的.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

限时删除!!

大家好,

我正在使用Visual Studio 2010,但不知道怎么了.我收到一条错误消息:对象引用未设置为对象的实例".

该错误不应该存在,因为我想我实例化了该对象.

请在下面检查我的代码:

Hi Guys,

I am using Visual Studio 2010 and I don''t know what''s wrong. I got an error that says - "Object reference not set to an instance of an object".

The error shouldn''t be there because I think I instantiated the object.

Please check my codes below:

Line:565   Dim Roles As New RolesFunctions

Line:566   If LCase(sLoginType) = LCase("admin") Then
Line:567      Call Roles.GetAdminRoles(nCompanyId, sStudentId)


...

错误指向第567行,说-对象引用未设置为对象的实例".

RolesFunctions是GetAdminRoles方法所在的公共类.

我会错过代码中的某些内容吗?

谢谢,

Hifiger


...

The error is pointing at line 567, says - "Object reference not set to an instance of an object".

The RolesFunctions is a Public Class where the GetAdminRoles method is located.

Do I missed something in the codes?

Thanks,

Hifiger

推荐答案


这篇关于怎么了?你调用的对象是空的.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

1403页,肝出来的..

09-06 13:53