I am working on a web application in Visual Studio 2012. I am using eConnect to create Purchasing Invoices that match to POs, so I am using the POPEnterMatchInvoiceType. I have successfully created a record for a Drop-Ship PO with AutoInvoice = 0 and nothing passed to POPMtchShpRcpt and ShipRCTLNNM. However, I am getting an error when I try to create a record for a Standard PO with 2 lines that have been received. I have tried using AutoInvoice = 1 and alternately manually submitting POPMtchShpRcpt, ShipRCTLNNM, and QTYINVCD. I get the same results either way. I know that the PO has been received. If I use the Enter/Match Invoices GUI in GP, I can use the Auto-Invoice button to invoice the same lines. I can't figure out what I'm missing. Below is the error. Any thoughts on what I'm doing wrong?
Error Number = 5309 Stored Procedure= taPopEnterMatchInvLine Error Description = There are no shipments to match against
Node Identifier Parameters: taPopEnterMatchInvLine
POPRCTNM = 20000002
PONUMBER = PO0301845
Related Error Code Parameters for Node : taPopEnterMatchInvLine
AutoInvoice = 1
<taPopEnterMatchInvLine>
<POPRCTNM>20000002</POPRCTNM>
<PONUMBER>PO0301845</PONUMBER>
<ITEMNMBR>072-28358 </ITEMNMBR>
<VENDORID>HUT00002</VENDORID>
<UNITCOST>0</UNITCOST>
<EXTDCOST>0</EXTDCOST>
<AUTOCOST>1</AUTOCOST>
<AutoInvoice>1</AutoInvoice>
</taPopEnterMatchInvLine>
Stack Trace:
at Microsoft.Dynamics.GP.eConnect.EntityMessageProcessor.ExecuteSqlCommands(XElement transactionNode, EntityMessage message)
at Microsoft.Dynamics.GP.eConnect.eConnectMethods.ProcessMessageImport(EntityMessage message)
at Microsoft.Dynamics.GP.eConnect.eConnectMethods.EntityImportImplementation(String connectionString, String sXML, Boolean isTransaction)
at Microsoft.Dynamics.GP.eConnect.eConnectMethods.CreateTransactionEntity(String connectionString, String sXML)
at Microsoft.Dynamics.GP.eConnect.Service.CreateTransactionEntity(String ConnectionString, String sXML)
Exception type:
Microsoft.Dynamics.GP.eConnect.eConnectException
Exception message:
Error Number = 5309 Stored Procedure taPopEnterMatchInvLine Error Description = There are no shipments to match against
*This post is locked for comments