Somacon.com: Articles on websites & etc.

§ Home > Index > C and C# Programming

Sage 50 Accounting SDK Download Links US-Canada

Sage 50 Complete Accounting is the new name for Peachtree Accounting. The SDK (software development kit) is currently not easily accessible via the Sage website. I found the important download links in the community forums and have listed them below.

Sage 50 still supports the COM API (as well as the new .Net API and old OLEDB/ODBC API). There is a chart in the SDK documentation that compares the features. To upgrade from Peachtree, just update your reference from Interop.PeachtreeAccounting.dll to Interop.PeachwServer.dll (located in the c:\Program Files\Sage Software\Peachtree) folder. Change the import statements from "using PeachtreeAccounting;" to "Interop.PeachtreeAccounting.dll;". The upgrade should be seamless.

Sage 50 Complete Accounting - US Edition - SDK

Sage 50 Complete Accounting - Canadian Edition - SDK

Resolving Build Errors with the COM API

Retrieving the COM class factory for component with CLSID {C2D727E5-6288-4018-9F40-3785AB187583} failed due to the following error: 80040154 Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG)). -2147221164

To resolve this, be sure to use the SDK version that correponds to the version of Sage 50 you have installed.
For example, if you have Sage 50 2020, use the latest edition of the Sage 50 SDK 2020.
For example, if you have Sage 50 2019, use the latest edition of the Sage 50 SDK for 2019, which is 2019.2.

You can not have two versions of the Sage 50 SDK installed at the same time. You will have to uninstall the incompatible one, and install the compatible one.

Do not run the command from an elevated command prompt like: %windir%\SysWoW64\regsvr32.exe Interop.PeachwServer.dll
It will give you this error and it will not resolve the problem:

RegSvr32
The module "Interop.PeachwServer.dll" failed to load.
Make sure the binary is stored at the specified path or debug it to check for problems with the binary or dependent .DLL files.
The specified module could not be found.

Be sure to copy Interop.PeachwServer.dll to the "bin" folder of the executable, and add a reference to it using the 'Browse' to file button.

If you see the build errors listed below, select the Interop.PeachwServer.dll and in the Properties dialog, select "False" for "Embed Interop". By default, it is "True", so you will need to manually change this.


Error CS0656 Missing compiler required member 'Microsoft.CSharp.RuntimeBinder.Binder.Convert'
Error CS1752 Interop type 'LoginClass' cannot be embedded. Use the applicable interface instead.


Created 2013-01-15, Last Modified 2020-01-29, © Shailesh N. Humbad
Disclaimer: This content is provided as-is. The information may be incorrect.