That means i believe your Group Envelope section(GCEnvelope) and Transaction set might be having some compliance errors(means not in the format according to the used edi template).
So my suggesion is pls make a compliance check using built in service (processEnvelope)in edi package, before you sending the edi document to TN (wm.tn:receive or wm.tn.doc.xml:routeXML).
With this builtin service you can validate the final edi document with Error True or False.
If Errors is false then your edi document is formatted well according to delimiters and segments.
After you tested the edi document you disable the service processEnvelope.
Thanks.
#webMethods#Adapters-and-E-Standards#Integration-Server-and-ESB