Plug-ins > FM Books Connector

Linking a Sales Order to an Invoice

(1/2) > >>

mvoogt:
I create all of my Sales Orders in FMP and them push them to QB. I then pull the TxnID back to FMP on that sales order because I immediately want to invoice it that Sales Order.

The problem that I am having is connecting the Sales Order to the Invoice I want to make. I am trying to create an Invoice in FMP and use the LinkToTxnID request however I am just getting errors back and cannot seem to link the two.

Please Help!

Melinda DePalma:
In order to better answer can you please let me know what exact errors you are receiving and provide a sample of your script?

mvoogt:
I have attached 2 screen shots to this post of my sample scripts.

The way that I initially made this script was to just push over an invoice with line items. It works fine when I do just that. However when I add the step "LinkToTxnID" it no longer works. I think I may be using that request wrong. I copied this script initially out of the PCQB demo file however since in the demo file the "LinkToTxnID" is not used, I am not too familiar with it.

I tried to refer to the QB SDK programer's guide (where it does have a section on using the LinkToTxnID request) however because it doesn't reference the PCQB plugin directly I found it hard to understand how to use the LinkToTxnID request correctly.

The Screen Shots

The first one is a script trying to just push over an invoice (with no line items) and using the LinkToTxnID.... hoping that it would pull the Line Items from the  QuickBooks ID it was linking to. However in the gResult field I just get !!ERROR!!

The second example I duplicated the sales order in FMP and made it an "invoice". Then I tried to push over that entire invoice (with the Line Items) and use the LinkToTxnID hoping it would relate the line items back to that original sales order. However in the gResult field I also just get !!ERROR!!

Finally, you asked what errors I am getting however the only thing that shows up in the gResults field is "!!ERROR!!" I don't get a number or anything.

Thank you so much for your time! Please let me know if you need more details or if my explanations are confusing.

-Matt

Melinda DePalma:
If you download the latest bundle and read the Developer's Guide then this should clarify most of your questions about how to use the OSR to develop your scripts using the plug-in, error capturing and how to create requests/responses. Basically anytime you receive an !!ERROR!! call the PCQB_SGetStatus function in order to obtain a full description of the error. The text returned by this function should help troubleshoot script or logic failures. What is the text returned by this function ?

Also here is a direct download link to the bundle which contains the latest Developer's Guide as we recommend you read this latest documentation twice before developing your scripts:
http://www.fmbooksconnector.com/downloads/FMBooksConnector.zip

Please let me know.

mvoogt:
I got the error code:

------------

CODE: -1000
SEVERITY: failed validation
MESSAGE: Error at LinkToTxnID
Reason:   Element 'LinkToTxnID' is unexpected according to content model of parent element 'InvoiceAdd'.
Expecting: ItemSalesTaxRef, Memo, CustomerMsgRef, IsToBePrinted, CustomerSalesTaxCodeRef, InvoiceLineAdd, InvoiceLineGroupAdd.

Field Value:   BD3A3-1246394246

------------

That field value is the QB ID of the Sales Order I am trying to connect to

Navigation

[0] Message Index

[#] Next page

Go to full version