************** 异常文本 **************
System.NullReferenceException: 未将对象引用设置到对象的实例。
   在 CSL.TrustedServer.Stop() 位置 C:\Users\ClarIDy\Desktop\CS461 Access Control 2.0.0.5\CS461_HL_API.cs:行号 3789
   在 CS461_Access_Control.frmMain.stopReadTags() 位置 C:\Users\ClarIDy\Desktop\CS461 Access Control 2.0.0.5\frmForm1.cs:行号 264
   在 System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
   在 System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
   在 System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
   在 System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
   在 System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
   在 System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
   在 System.Windows.Forms.Control.WndProc(Message& m)
   在 System.Windows.Forms.ToolStrip.WndProc(Message& m)
   在 System.Windows.Forms.MenuStrip.WndProc(Message& m)
   在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   在 System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)以上是我运行程序时,点击停止程序时报的错误信息。程式是放在服务器E盘的,可以点击查询功能,并返回数据。该程序是在我笔记本上编写,于其他电脑上运行均无错误,只是放到服务器上运行时就这样了。程式是打包成.exe文件运行的。

解决方案 »

  1.   

    C:\Users\ClarIDy\Desktop\CS461 Access Control 2.0.0.5\frmForm1.cs:路径配置什么,要查一下了.另外,可能你客户机安装什么组件了.
    或服务器多了什么,造成了冲突造成的.
      

  2.   

    我已经将程序放在服务器的低槽了,而且在其他client运行都很正常!请大侠指教。
      

  3.   

    咕~~(╯﹏╰)b  ,我的C#程序是打包成.exe文件放在服务器端运行的,所有的代码和控件都是封装的,ClarIDy是我计算机的用户名,而服务器的用户名是Administrator,我有点纳闷。为什么在服务器端运行还会报错会是我计算机的名字