N/A xmlinterop.dll (64 bit) error code 14


I am working on using the 64-bit version of the xmlinterop.dll. I can only get "error code 14 - Connection to OneWorld failed".
I've tried sending in bad xml, bad username/password, to force a different error, but only get error 14, which doesn't really tell me anything about why it's not getting through.

We have an old C++ solution working with the 32-bit dlls; but upgrading to C# & 64-bit dlls. I can use our old solution and get accurate responses, so I know the server is accepting xml calls. The server is 64-bit install.

Here's my code:

public static extern IntPtr jdeXMLRequest(
string szHostName,
ushort lPort,
int lTimeout,
string XML_Msg_IN,
int lSize);

internal static void CallE1() {

string xml = "<?xml version=\"1.0\" encoding=\"UTF-8\"?><jdeRequest type=\"callmethod\" user=\"USER\" pwd=\"PASS\" environment=\"ENV\" session=\"\" sessionidle=\"3600\" role=\"*ALL\"><callMethod name=\"METHOD\" app=\"APP\"><params /></callMethod></jdeRequest>";

string host = "SERVER";
int port = 1234;
int timeout = 360;
int length= 0; //tried length as 0 and xml.Length

var rsp = jdeXMLRequest(host, (ushort)port, timeout, xml, length);

string response = Marshal.PtrToStringAnsi(rsp);