首先看看工控机的系统是否安装windows installer4.5
其次看看是否需要安装 visual c++ 2010运行库(调用c++ dll需要)
最后看项目属性中生成中的目标平台是否x86

解决方案 »

  1.   

    记录Log,使用try catch把错误记到文本中
      

  2.   

    软件自身未捕获的异常和线程异常可以通过全局的事件来捕捉
    Application.ThreadException += new System.Threading.ThreadExceptionEventHandler(Application_ThreadException);
    AppDomain.CurrentDomain.UnhandledException += new UnhandledExceptionEventHandler(CurrentDomain_UnhandledException);Application.Run(new Form1());
     static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e)
            {
                //get log 
            }        static void Application_ThreadException(object sender, System.Threading.ThreadExceptionEventArgs e)
            {
                //get log
            }通过日志查看,比猜测来的更直接有效些