System.IO.FileNotFoundException: 未能加載文件或程序集“System.EnterpriseServices.Wrapper.dll”或它的某一個依賴項。系統找不到指定的文件。 文件名:“System.EnterpriseServices.Wrapper.dll” ---> System.IO.FileNotFoundException: 未能加載文件或程序集“System.EnterpriseServices.Wrapper.dll”或它的某一個依賴項。系統找不到指定的文件。 文件名:“System.EnterpriseServices.Wrapper.dll” ---> System.IO.FileNotFoundException: 系統找不到指定的文件。 (異常來自 HRESULT:0x80070002)
在 System.EnterpriseServices.ContextUtil.get_IsInTransaction()
在 System.Data.Common.ADP.IsSysTxEqualSysEsTransaction()
在 System.Data.Common.ADP.NeedManualEnlistment()
當出現這個問題的時候 ,此文件夾內容是空的
C:\WINDOWS\assembly\GAC_32\System.EnterpriseServices\2.0.0.0__b03f5f7f11d50a3a\
解決方法:
- 將(如圖).net framework 3.5(包含.net2.0 和3.0)的勾去掉, 完成后會要求重啟電腦
- 重新打開原有exe程序,系統會提示需要安裝.net,安裝完成后不必重啟,打開exe即可