A Load or Unload statement has referenced an invalid object or control. This error has the following causes and solutions: You tried to load or unload an object that isn't a control or form, such as Screen, Printer, or Clipboard. 
Delete the erroneous statement from your code.You tried to load or unload an existing control that isn't part of a control array. For example, assuming that a TextBox with the Name property Text1 exists, Load Text1 will cause this error. 
Delete the erroneous statement from your code or change the reference to a control in a control array.You tried to unload a Menu control in the Click event of its parent menu. 
Unload the Menu control with some other procedure.You tried to unload the last visible menu item of a Menu control. 
Check the setting of the Visible property for the other menu items in the control array before trying to unload a menu item or delete the erroneous statement from your code

解决方案 »

  1.   

    试图加载或卸载一个现存的控件,但它不是控件数组的一部分。例如,假设 Name 属性为 Text1 的 TextBox 存在,则 Load Text1 会产生该错误。(摘自msdn) 
    ================================================================CSDN 论坛助手 Ver 1.0 B0402提供下载。 改进了很多,功能完备!★  浏览帖子速度极快![建议系统使用ie5.5以上]。 ★  多种帖子实现界面。 
    ★  保存帖子到本地[html格式]★  监视您关注帖子的回复更新。
    ★  可以直接发贴、回复帖子★  采用XML接口,可以一次性显示4页帖子,同时支持自定义每次显示帖子数量。可以浏览历史记录! 
    ★  支持在线检测程序升级情况,可及时获得程序更新的信息。★★ 签名  ●  
         可以在您的每个帖子的后面自动加上一个自己设计的签名哟。Http://www.ChinaOK.net/csdn/csdn.zip
    Http://www.ChinaOK.net/csdn/csdn.rar
    Http://www.ChinaOK.net/csdn/csdn.exe    [自解压]
      

  2.   

    用set 控件变量名 = nothing