Could not load file or assembly Sage.Peachtree.Domain

SOLVED

Hi

I have written a windows service that speaks to Sage 50. It runs on three computers. On only one computer, I see this in the logs:

2020-07-09 11:01:27.277 -04:00 [DBG] Could not load file or assembly 'Sage.Peachtree.Domain, Version=2020.2.0.219, Culture=neutral, PublicKeyToken=d06c16dde04d83e4' or one of its dependencies. The system cannot find the file specified.
System.IO.FileNotFoundException: Could not load file or assembly 'Sage.Peachtree.Domain, Version=2020.2.0.219, Culture=neutral, PublicKeyToken=d06c16dde04d83e4' or one of its dependencies. The system cannot find the file specified.
File name: 'Sage.Peachtree.Domain, Version=2020.2.0.219, Culture=neutral, PublicKeyToken=d06c16dde04d83e4'
   at Sage.Peachtree.API.PeachtreeSession.Begin(String applicationIdentifier)
   at IWErpnextPoll.ErpnextService.OpenSession(String appKeyID)

Consequently, the said computer never gets to connected to Sage. What could be the cause of this?

Parents Reply
  • +1 in reply to tundebabzy
    verified answer

    Hello, please make sure that you are logged in as Windows Administrator and have full control on the Sage 50 US runtime folders. Keep UAC disabled if possible. Also, do not use Reference.CopyLocal=True setting in your Visual Studio project. Reference the DLL directly from the Sage 50 runtime folder.

Children