eConnect: The creator of this fault did not specify a Reason

eConnect WCF exception handling

For this example a WCF service reference to the server endpoint running the GP2010 eConnect integration service as a reference named “GPeConnect” is used.

If an exception were to occur from eConnect on say the CreateEnity mehods, and the exception examined as type system.exception, then the following message is found from ex.message,

System.ServiceModel.FaultException: The creator of this fault did not specify a Reason

To retrieve the error message from econnect that we are interested in, use the System.ServiceModel.FaultException class as shown below. By accessing the Detail.Message property, it is possible to get message of interest.


Microsoft Free eBooks

Microsoft Free eBooks


nebytesAt my local user group NEByes yesterday evening we enjoyed a session on Mobile Business Intelligence Using Microsoft (Jen Stirrup) and Tableau and SharePoint Virtualisation (Level 100) IT Pro or Technical Beginner (John Timney)

The following free ebooks were pointed out, although I knew some were available, it was a prod to go and investigate, here are the ones I found…



eConnect 2010 - eConnectProcsRunFirst

eConnectProcsRunFirst is not part of eConnectProcessInfo for eConnect 2010

eConnectProcsRunFirst is not present in the schema for GP2010 eConnect. Just to confuse people, the documentation in the eConnect SDK still references it in quite a few places still.

Converting eConnectProcsRunFirst to use eConnect 2010

What to do when converting previous versions? It seems to be very simple, the order of the nodes in the XML document submitted to eConnect defines the run order. So if a custom stored procedure is required to run first, ensure it is placed first in the XML document relative to the item it must run ahead of. Yes it is that simple!


Dynamics GP Macro Reference II

After working to support Dynamics GP Macros in our Visual Studio add in for GP I discovered a new layer of macro language not touched on in Mark Polno’s publication of Kevin Gross’s GP Macro Reference.

How to use macros to activate .NET add in forms

Use the following command:
NewActiveWin dictionary ‘default’ form [customID] window [.NET form name]

[customID] seems to be a jumble of characters to uniquely identify this as a addin form.
[.NET form name] is the .NET form name for the form we are trying to show.
NewActiveWin dictionary 'default'  form pARthOSt window AuxFormIV00101


Macro commands passed to RecordMacroItem

Any commands sent to the Macro subsystem from the .NET form are wrapped in a wrapper named “ShellCommand”. To record macro commands to the currently recording macro, call the following method on the form derived from Microsoft.Dexterity.Shell.DexUIForm.

RecordMacroItem(MacroCommandText as string, MacroComment as string)

The text passed in MacroCommandText is wrapped in a “ShellCommand” statement in the resulting macro file, as shown here where the highlighted text represents the string passed as the MacroCommandText when the macro was recorded;

ShellCommand 'ViewWebsiteInformationToolStripMenuItem_Click'
ShellCommand 'ClickHit field "btnOK"'


Long Macro Lines

There is another scenario that must be dealt with, the Add in macro equivalent of
ContTypeTo field 'Account Description' , 'nt 1'
This command would continue typing into the field Account Description appending to whatever is already there. The macro system wraps the whole lot in a ShellCommandBegin block, with each line starting ShellCommandAppend. The following is an example of this arrangement:

ShellCommandAppend 'TypeTo field "rebHTMLText", "<ul>
<li>HDMI cable with swivel ends - up to 180 De'

ShellCommandAppend 'grees </li>
<li>Reduces stress on your cables and risk of disconnecting </li>

ShellCommandAppend 'i>Provides both high definition video and multi-channel audio connection between'
ShellCommandAppend ' digital high definition AV sources such as Blu-ray, DVD players etc. </li>

ShellCommandAppend 'Transfer bandwidth: 10.2Gbps / 340Mhz (v1.3)</li>
<li>Signal Type: Transmission '

ShellCommandAppend 'minimised differential signalling (TMDS)</li>
<li>Connector Type: Gold plated </'

ShellCommandAppend 'li>