Quantcast
Channel: Microsoft Dynamics GP Forum - Recent Threads
Viewing all articles
Browse latest Browse all 32807

eConnect.eConnectException: Sequence contains no elements

$
0
0

I have an application that syncs a document library on Sharepoint with KL using eConnect. Basically on a person approving a document, a work flow gets kicked of, and the workflow sends the invoice to GP2013. Seemingly randomly we are getting this error[1] when eConnectMethods.CreateTransactionEntity is called. After that when eConnectMethods.Dispose is called another error is thrown[2].

The frustrating thing about this error is if we rerun the workflow, it works no problems. Same code and same xml and the error seems to not follow any patterns.

[1]

CreateTransactionEntity eConnectException: Microsoft.Dynamics.GP.eConnect.eConnectException: Sequence contains no elements 
   at Microsoft.Dynamics.GP.eConnect.ServiceProxy.CreateTransactionEntity(String connectionString, String xml) 
   at Microsoft.Dynamics.GP.eConnect.eConnectMethods.EntityImportImplementation(String connectionString, String sXML, Boolean isTransaction) 
   at Microsoft.Dynamics.GP.eConnect.eConnectMethods.CreateTransactionEntity(String connec tionString, String sXML) 
   at Mysolution.namespace.SendToGreatPlains.submit(eConnectType eConnType, String dbConn, String& errorMessage) 

[2]

System.ServiceModel.CommunicationObjectFaultedException: The communication object, System.ServiceModel.Channels.ServiceChannel, cannot be used for communication  because it is in the Faulted state. 
   at System.ServiceModel.Channels.CommunicationObject.Close(TimeSpan timeout) 
   at System.ServiceModel.Channels.ServiceChannelFactory.OnClose(TimeSpan timeout) 
   at System.ServiceModel.Channels.ServiceChannelFactory.TypedServiceChannelFactory`1.OnClose(TimeSpan timeout) 
   at System.ServiceModel.Channels.CommunicationObject.Close(TimeSpan timeout) 
   at System.ServiceModel.ChannelFactory.OnClose(TimeSpan timeout) 
   at System.ServiceModel.Channels.CommunicationObject.Close(TimeSpan timeout) 
   at Microsoft.Dynamics.GP.eConnect.ServiceProxy.Dispose() 
   at Microsoft.Dynamics.GP.eConnect.eConnectMethods.Dispose() 
   at Mysolution.namespace.SendToGreatPlains.submit(eConnectTyp e eConnType, String dbConn, String& errorMessage) 

 

I've tried this article's suggestion:

http://support.microsoft.com/kb/2539263

I've also tried many changes in the code.

These are on on good hardware and the network between them is solid.

Any suggestions? Do you need more information?


Viewing all articles
Browse latest Browse all 32807

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>