Plug-ins > FM Books Connector

Bringing in BillAddress into Filemaker from Quickbooks


I'm sure I have some silly mistake in my scripting, but for the life of me I can't figure it out. I'm trying to bring in all the customer information from QB into FM, It is bringing in everything except for the items that are attached to the BillAddress:: tags. I've attached my script. Please point out my mistake.

Melinda DePalma:
According to the OSR, whatever address you specify in this aggregate must not result in an address greater than 5 lines, otherwise you'll get a runtime error, because QuickBooks doesn't support addresses more than 5 lines.
There are two ways to specify an address within this aggregate:
1.Using Addr1 through Addr3 along with the other possible aggregate elements, such as City, State, Postalcode.
2.Using Addr1, Addr2, Addr3, Addr4, and Addr5 to fully specify the address. If you use this so called "address block" approach, you cannot use any other address elements, such as City, State, etc. (Note: this approach is not valid for EmployeeAdd/Mod/Query)
If you use the address block approach above, the lines Addr1...Addr5 are each printed as a separate line on the transaction, and the values are returned in the Ret object under the aggregate ShipAddressBlock or BillAddressBlock.

It appears that you are specifying too many address elements, which is not supported by QuickBooks.

Thanks for your reply. First off I'm trying to pull info from QB into Filemaker, not post to QB. The original script that I tried only had Addr1 and Addr2, I changed it back just to make sure but it still won't bring in any of those elements with the BillAddress. Everything else comes in fine.

The problem is with the "IncludeRetElement" fields in the request.  The OSR states that "You must specify a top-level element or aggregate...You cannot specify fields within an aggregate...."  This means that you must get the entire aggregate instead of single fields within the aggregate.  Since "BillAddress" is an aggregate the rule applies.

Aggregates are elements that have childern such as BillAddress, CreditCardInfo, and ParentRef.

In your request omit all of the PCQB_RqAddFieldWithValue( "IncludeRetElement" ; "BillAddress::..." ) and include just a single call to PCQB_RqAddFieldWithValue( "IncludeRetElement" ; "BillAddress" )

That should fix the problem.


Yep that was it, Thanks  :)


[0] Message Index

Go to full version