Friday, June 22, 2018

Using eConnect from Dexterity. Part 1.

As I mentioned in a previous post eConnect is the tool of choice when integrating to Dynamics GP.  Dexterity is the tool of choice for customizing Dynamics GP.  You can use Dexterity to access all the tables in GP, and you can CRUD all that data as you'd like.  However you do so at the risk of introducing corruption in the GP database if you don't know exactly what you are doing.

Add to that the hazards of upgrades and frankly I'd just assume avoid all that trouble.  This is where eConnect comes to the rescue!

eConnect is the tool of choice for integrations to GP because it acts as an API to the data layer by way of the business logic.  This means it will default data where it can, and prevent you from putting invalid data where you can't.  And it's almost upgrade-proof.  There are situations where upgrades introduce new requirements on eConnect, but they are rare.  This makes upgrades much more manageable.

So if you are writing Dexterity code and want to integrate data to GP you can certainly use eConnect.  However it helps to understand how eConnect works.

As a longtime Scribe user I've learned that you need to use a bottom-up approach when integrating.  Since Scribe bases its GP integration on eConnect I never realized that the reason it did that was because eConnect required it.  It wasn't until I started to use eConnect directly that I realized Scribe did it this way because eConnect did it that way.

What this means is you have to insert your detail transactions before the header.  For example if you are trying to create a GL transaction you will have to create all the GL lines before you can insert the GL header.  This applies to most transactions in Dynamics GP.

If you don't have any experience with Scribe or eConnect (and perhaps even if you do) I'd suggest installing the eConnect SDK that comes with GP.  While this is not required there's a nugget in there that is the eConnect Programmer's Guide.  When you install the SDK it installs the Guide in both CHM and PDF form (Program Files (x86)\Microsoft Dynamics\eConnect xx\Help.)  In the back of the CHM is the eConnect Node References that will really help out.

For some odd reason Microsoft left the Node reference out of the PDF version of the guide.

In my next post I'll describe how I put eConnect to work from inside of Dexterity.

No comments:

Post a Comment