Bonjour
J'ai développer une application qui fonctionne avec une DLL Erp Connect pour prendre des données depuis SAP.
Ça marche tip-top si je compile en .Net Framework 4.0, avec la référence de la DLL ERPConnect 4.0, et la DLL intégré au projet 4.0, de plus j'ai fait ça :
Aujourd'hui je veux passer mon programme en Framework 4.5.2
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10 static Assembly CurrentDomain_AssemblyResolve(object sender, ResolveEventArgs args) { using (var stream = Assembly.GetExecutingAssembly().GetManifestResourceStream("BTime.ERPConnect40.dll")) { byte[] assemblyData = new byte[stream.Length]; stream.Read(assemblyData, 0, assemblyData.Length); return Assembly.Load(assemblyData); } }
J'intègre donc la DLL 4.5 d'ERP Connect, je change le logiciel pour compiler en 4.5.2, sur mon PC en Win10 ça marche nickel, mais sur un PC en Seven avec Framework 4.5.2 installé j'obtiens une erreur à la connexion (utilisation de la DLL ERPConnect ?) le logiciel se lance bien mais plante à la connexion avec SAP .
Voici l'observateur d'événements
The description for Event ID 1000 from source Application Error cannot be found. Either the component that raises this event is not installed on your local computer or the installation is corrupted. You can install or repair the component on the local computer.
If the event originated on another computer, the display information had to be saved with the event.
The following information was included with the event:
Btime.exe
1.0.0.0
56e7c36e
KERNELBASE.dll
6.1.7601.19135
56a1c680
e0434352
000080d7
ef8
01d17e9286752f7b
C:\BTime\Btime.exe
C:\Windows\system32\KERNELBASE.dll
cf02c45c-ea85-11e5-8ad9-000bab66d982
The handle is invalidQui peut m'aider ? Merci.The description for Event ID 1026 from source .NET Runtime cannot be found. Either the component that raises this event is not installed on your local computer or the installation is corrupted. You can install or repair the component on the local computer.
If the event originated on another computer, the display information had to be saved with the event.
The following information was included with the event:
Application: Btime.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.IO.FileLoadException
Stack:
at BTime.MainForm.ConnectSAP(System.String)
at BTime.MainForm.LoadBadge(BadgeRead)
at BTime.MainForm.MyReader_NewMediaRead(BadgeRead)
at DesktopReaderControl.ReaderControl.(ChipType, System.String, Int32, Int32)
at DesktopReaderControl.ReaderControl+..()
at System.Threading.ThreadHelper.ThreadStart_Context(System.Object)
at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
at System.Threading.ThreadHelper.ThreadStart()
The handle is invalid
Partager