web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Microsoft Dynamics GP (Archived)

GP 2010 - econnect - Shipment/Invoice data feed

(0) ShareShare
ReportReport
Posted on by

I am trying to create a Receivings Transaction Entry using the Shipment/Invoice option  using GP 2010 via econnect.

 

I use the following nodes.

<taPopRcptHdrInsert>  & <taPopRcptLineInsert>

I can create a header document fine but I am getting the following error ( Invalid object name 'PA43001' ) when I try to create a NONINVENTORY=1 line items.

 

Here is the XML I have so far. I am trying to use AUTOCOST option. If I change the NONINVEN = 0 then it complains about item not being in inventory.

 

 

<?xml version="1.0" encoding="utf-8"?><eConnect xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><POPReceivingsType><eConnectProcessInfo xsi:nil="true" /><taRequesterTrxDisabler_Items xsi:nil="true" /><taUpdateCreateItemRcd xsi:nil="true" /><taUpdateCreateVendorRcd xsi:nil="true" /><taCreateVendorAddress_Items xsi:nil="true" /><taPopRcptLotInsert_Items xsi:nil="true" /><taPopRcptSerialInsert_Items xsi:nil="true" />

<taPopRcptLineInsert_Items>

<taPopRcptLineInsert>

<POPTYPE>3</POPTYPE>

<POPRCTNM>RCT000977</POPRCTNM>

<PONUMBER>PO000462</PONUMBER>

<ITEMNMBR>ECM</ITEMNMBR>

<VENDORID>VEND001</VENDORID>

<VNDITNUM>ECM</VNDITNUM>

<NONINVEN>1</NONINVEN>

<UNITCOST>0</UNITCOST>

<EXTDCOST>0</EXTDCOST>

<SUBTOTAL>0</SUBTOTAL>

<QTYSHPPD>0</QTYSHPPD>

<AUTOCOST>1</AUTOCOST>

<Purchase_IV_Item_Taxable>3</Purchase_IV_Item_Taxable>

</taPopRcptLineInsert>

</taPopRcptLineInsert_Items><taPopRcptMultiBin_Items xsi:nil="true" />

<taPopRcptLineTaxInsert_Items xsi:nil="true" />

<taPopRctUserDefined xsi:nil="true" />

<taPopDistribution_Items xsi:nil="true" />

<taAnalyticsDistribution_Items xsi:nil="true" />

<taPopRcptHdrInsert>

<CREATEDIST>1</CREATEDIST>

<POPRCTNM>RCT000977</POPRCTNM>

<POPTYPE>3</POPTYPE>

<CREATEDIST>1</CREATEDIST>

<AUTOCOST>1</AUTOCOST>

<SUBTOTAL>0</SUBTOTAL>

<VNDDOCNM>invoice123</VNDDOCNM>

<receiptdate>04/10/2012</receiptdate>

<ACTLSHIP>04/10/2012</ACTLSHIP>

<BACHNUMB>TEST_BATCH01</BACHNUMB>

<VENDORID>VEND001</VENDORID>

</taPopRcptHdrInsert>

<taMdaUpdate_Items xsi:nil="true" /></POPReceivingsType></eConnect>

 

 

*This post is locked for comments

I have the same question (0)
  • Community Member Profile Picture
    on at
    Re: GP 2010 - econnect - Shipment/Invoice data feed

    Hi Nick,  I am having the same issue.  What did you do to correct this issue?

  • sandipdjadhav Profile Picture
    18,306 on at
    Re: GP 2010 - econnect - Shipment/Invoice data feed

    Hello,

    I am using eConnect Shipment/Invoice schema from version 9.0 for Non Invenotry Items and it working fine for me. I did created Custom WebService using same schema . Below is code it may help you to understand issue.

    Feel free to email me if you need any further assistance on same.

    THanks

    Sandip

    ///************************************************************************************************************************************************************************

     try
                {
                    string filename = "C:\\FuelManagement\\PurchaseReceiptInvoice.xml";

                    string sConnectionString = ConfigurationManager.ConnectionStrings["EConnectConnectionString"].ToString();  

                   SqlConnection sqlConnection = new SqlConnection(sConnectionString);
                    sqlConnection.Open();


                    POPReceivingsType PoShipmentInvioce = new POPReceivingsType();
                    System.Collections.ArrayList POP = new System.Collections.ArrayList();
                    taPopRcptLineInsert_ItemsTaPopRcptLineInsert[] LineItems = new taPopRcptLineInsert_ItemsTaPopRcptLineInsert[POReceiptItems.Count];
                    taPopRcptHdrInsert POHeader = new taPopRcptHdrInsert();
                    taPopDistribution_ItemsTaPopDistribution[] itemsDist = new taPopDistribution_ItemsTaPopDistribution[popDistributions.Count];
                    
                   

                    int sCnt = 0;

                    ////string ReceiptNo = NextPOReceiptTransactionNo();

                    ////UpdatePOReceiptTransactionNo(ReceiptNo, Convert.ToDateTime(Header.TransactionDate.ToString()));
                    //


                    int i = 0;
                       
                        foreach(taPopDistribution_ItemsTaPopDistribution Refdistri in popDistributions)
                        {
                           
                            taPopDistribution_ItemsTaPopDistribution ActDistri = new taPopDistribution_ItemsTaPopDistribution();
                            ActDistri.POPTYPE = Refdistri.POPTYPE;
                            ActDistri.POPRCTNM = Refdistri.POPRCTNM;
                             ActDistri.ACTINDX = Refdistri.ACTINDX;
                             ActDistri.DEBITAMT = Refdistri.DEBITAMT;
                             ActDistri.CRDTAMNT = Refdistri.CRDTAMNT;
                             ////if (i == 0)
                             ////  {
                             ////   ActDistri.CRDTAMNT =Refdistri.CRDTAMNT;
                             ////  }
                             ////  else
                             ////  {
                             ////      ActDistri.DEBITAMT=Refdistri.DEBITAMT;
                             ////  }
                            ActDistri.DISTTYPE =Refdistri.DISTTYPE;
                            ActDistri.VENDORID = Refdistri.VENDORID;
                            if (i == 0)
                            {
                                itemsDist[0] = ActDistri;
                            }
                            else
                            {
                                
                                itemsDist[i] = ActDistri;
                            }
                             i++;
                    }

                    foreach (POReceiptItem item in POReceiptItems)
                    {


                        //  MessageBox.Show(ReceiptNo);


                        taPopRcptLineInsert_ItemsTaPopRcptLineInsert POPLine = new taPopRcptLineInsert_ItemsTaPopRcptLineInsert();
                        POPLine.POPTYPE = item.PopType; //3;
                        POPLine.receiptdate = item.LineItemReceiptDate.ToString();
                        POPLine.POPRCTNM = item.ReceiptNo.ToString();
                        POPLine.ITEMNMBR = item.ItemNumber.ToString().Trim(); //"EXP";
                        POPLine.ITEMDESC = item.ItemDescription.ToString().Trim();// "EXP";
                        POPLine.VENDORID = item.VendorId.ToString().Trim();// "FUELMAN";
                        POPLine.VNDITNUM = item.VendorItemNumber.ToString().Trim(); //"EXP";
                        POPLine.NONINVEN = item.NonInventory; //1;
                        POPLine.QTYSHPPD = item.QtyShipped;// 1;
                        POPLine.QTYINVCD = item.QtyInvoiced;// 1;
                        POPLine.UNITCOST = item.UnitCost;// decimal.Parse(gridView.Rows[sCnt].Cells[30].Value.ToString());
                        POPLine.receiptdate = item.LineItemReceiptDate;
                      //  POPLine.UNITCOSTSpecified = true;
                        POPLine.UOFM = item.UOM;
                        POPLine.EXTDCOST = item.ExtendCost; //1 * decimal.Parse(gridView.Rows[sCnt].Cells[30].Value.ToString());
                       // POPLine.EXTDCOSTSpecified = true;
                         
                            POPLine.ProjNum = item.ProjectNumber; //gridView.Rows[sCnt].Cells[0].Value.ToString();
                        
                      
                        POPLine.CostCatID = item.CostCategory.ToString().Trim(); // "OTH01-" + NewCostCategory + "-FUEL"; // "OTH01-9-FUEL"; //gridView.Rows[sCnt].Cells[1].Value.ToString();
                        POPLine.UNITCOSTSpecified = true;
                        POPLine.EXTDCOSTSpecified = true;
                        POPLine.LOCNCODE = item.LocationCode.ToString().Trim();// "MISC";
                        POPLine.INVINDX = item.InventoryActIndx;// 23;

                        //LineItems[0] = POPLine;

                        if (sCnt == 0)
                        {
                            LineItems[0] = POPLine;

                        }
                        else
                        {
                            LineItems[sCnt] = POPLine;

                        }
                        sCnt++;
                    }

                
                   
                    POHeader.POPRCTNM =Header.ReceiptNo.ToString().Trim();
                    POHeader.POPTYPE = Header.PopType; //3;
                    POHeader.VNDDOCNM = Header.VendorDocNumber; //VendorDocNo;
                    POHeader.receiptdate = Header.TransactionDate; //gridView.Rows[sCnt].Cells[7].Value.ToString();
                    POHeader.BACHNUMB = Header.BatchID; //"BATCHID";
                    POHeader.VENDORID = Header.VendorId; //"FUELMAN";
                    POHeader.CREATEDIST = Header.CreateDistribution; //1

                    PoShipmentInvioce.taPopRcptLineInsert_Items = LineItems;
                    PoShipmentInvioce.taPopRcptHdrInsert = POHeader;
                    PoShipmentInvioce.taPopDistribution_Items = itemsDist;

                    eConnectType eConnect = new eConnectType();
                    POPReceivingsType[] MyPOPReceivingsType = { PoShipmentInvioce };
                    eConnect.POPReceivingsType = MyPOPReceivingsType;

                    FileStream fs = new FileStream(filename, FileMode.Create);
                    XmlTextWriter writer = new XmlTextWriter(fs, new UTF8Encoding());


                    //     Serialize using the XmlTextWriter.
                    XmlSerializer serializer = new XmlSerializer(eConnect.GetType());
                    serializer.Serialize(writer, eConnect);
                    writer.Close();


                    string PurchaseInvoiceDocument;
                    eConnectMethods eConCall = new eConnectMethods();

                    try
                    {

                        XmlDocument xmldoc = new XmlDocument();
                        xmldoc.Load("C:\\FuelManagement\\PurchaseReceiptInvoice.xml");
                        PurchaseInvoiceDocument = xmldoc.OuterXml;
                        try
                        {
                            eConCall.eConnect_EntryPoint(sConnectionString, EnumTypes.ConnectionStringType.SqlClient, PurchaseInvoiceDocument, EnumTypes.SchemaValidationType.None, "");
                        }
                        catch (eConnectException exp) // The eConnectException class will catch any business logic releated errors from eConnect.
                        {
                            throw exp;
                        }
                        finally
                        {
                            eConCall.Dispose();
                            sqlConnection.Close();
                            sqlConnection.Dispose();
                            File.Delete("C:\\FuelManagement\\PurchaseReceiptInvoice.xml");
                        }
                    }
                    catch (Exception ex) // Catch any system error that might occurr.
                    {
                        //Console.Write(ex.ToString());
                        throw ex;
                        File.Delete("C:\\FuelManagement\\PurchaseReceiptInvoice.xml");
                    }

     

     

                }
                catch (Exception Ex) // The eConnectException class will catch any business logic releated errors from eConnect.
                {
                    throw Ex;
                }

    ///************************************************************************************************************************************************************************

  • Community Member Profile Picture
    on at
    Re: GP 2010 - econnect - Shipment/Invoice data feed

    Thank you for the answer. You are using ProjNum in LineItems section. Does this mean you are utilizing project accounting installed?

    The error I am getting is a table that is used by Project Accounting module but the customer do not own this module and this table does not exist. I dont understand why the system is looking for it if the module is not not installed and not being used.

    Any suggestions would be great.

  • Community Member Profile Picture
    on at
    Re: GP 2010 - econnect - Shipment/Invoice data feed

    Hi,  Nick I finally got mine to work by installing GP 2010 service pack 2.   Give that a try!  I could not find any answers for our issue, so I decided to search on Project Accounting instead.  I found an issue which was similiar so I thought I would give it a shot.  

    www.timwappat.info/.../econnect.aspx

  • sandipdjadhav Profile Picture
    18,306 on at
    Re: GP 2010 - econnect - Shipment/Invoice data feed

    Patti,

    I think I got saved because Project Accounting is installed. Thanks for posting solution.

    Thanks

    Sandip

  • Community Member Profile Picture
    on at
    RE: GP 2010 - econnect - Shipment/Invoice data feed

    I'm doing the same thing (except just a Shipment type) and getting the same error on GP 2010 SP 2. I don't see anything in the fix list for SP 3 or SP 4 specifying this issue was fixed. Is this still an issue?

  • Community Member Profile Picture
    on at
    RE: GP 2010 - econnect - Shipment/Invoice data feed

    I think this ended up being a bug in GP. GP thinks you have project accounting installed and looks for this table. Ms site had scripts to run that cleans up the system or check the modules installed and make sure Project accounting not selected.

  • Suggested answer
    Community Member Profile Picture
    on at
    RE: GP 2010 - econnect - Shipment/Invoice data feed

    Yeah, I agree with this. I ended up opening a case and they sent me an updated script that addressed the issue. I'm not sure on the service pack it was rolled out in, but definitely by 2010 SP 4.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics GP (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans