Using XMLInterop.DLL and getting System.AccessViolationException error.
I have VB.Net Windows service that uses XMLInterop to get a next number from JDE. When the service tries to run JdeXMLRequest the service stops running and the following error is generated in the Event Viewer. I am running the service on Windows 7.
Application: KronostoJDE.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.AccessViolationException
Stack:
at Microsoft.Win32.Win32Native.CoTaskMemFree(IntPtr)
at KronostoJDE.helper.JdeXMLRequest(System.String, Int32, Int32, System.String, Int32)
at KronostoJDE.helper.SendXMLRequest(System.String)
at KronostoJDE.helper.GetNextNumber()
at KronostoJDE.Service1.tmrCheck_Tick(System.Object, System.EventArgs)