Object reference not set to an instance of an object.请问,

来源:学生作业帮助网 编辑:作业帮 时间:2024/05/01 05:16:05
Object reference not set to an instance of an object.请问,

Object reference not set to an instance of an object.请问,
Object reference not set to an instance of an object.请问,

Object reference not set to an instance of an object.请问,
简单地说就是你调用的对象是空的
我用的是C#,
假如你这样用:
定义一个窗体 From A;(这里只是定义没有实例化)
然后没有实例化就调用A的show方法:A.show(),这样就会报楼主说的那个错了,
就好比我宣称要学英语,还没有动手开始学,领导就叫我去做同声翻译,这样肯定会出错啦