Plug-ins > FM Books Connector Online

Create item: how set "I sell this product..."


When creating a new item in QB, the code below runs with no error, but the resulting item is not associated with an income account.  The account is not showing on the account list, nor is it part of the xml returned when this account is queried.  The item cannot be used when manually creating an invoice.

The workaround is to manually edit the item in QBOE, then click the "I sell this product/service to my customers" check box.  Once this is done, the correct income account DOES appear as already be chosen in the Income Account field.  Saving this manually-adjusted item causes the accounts to show up in the item list and queries.  Also the item can be manually selected in a QB invoice.

What am I doing wrong with my plugin calls when creating an item?  The ESR for items doesn't seem to have a control for the "I sell this product..." check box.  Instead of referring to the income account by name, I've also tried by ID.  But this throws an error.

Any ideas?
Thanks in advance!

PCQO_RqNew("Create"; "Item")
PCQO_RqAddFieldWithValue("Name"; "test 140719_15 income")
PCQO_RqAddFieldWithValue("IncomeAccountRef::name"; "Services")
//PCQO_RqAddFieldWithValue("IncomeAccountRef::value"; "15")    // DIDN'T HELP
PCQO_RqAddFieldWithValue("ExpenseAccountRef::name"; "Cost of Goods Sold")
//PCQO_RqAddFieldWithValue("IncomeAccountRef::value"; "7")      // DIDN'T HELP

Jerel Malong:
Hi pjreagan.

I've had a similar scenario from my experience when using the FM Books Connector Online- It's like you said, the ESR was not much help in this case.

Through trial and Error I found out that in order to mark that checkbox you need to pass, in the following order:


Hope this helps!

Excellent!  That worked.

It's really weird that the "V" of "IncomeAccountRef::Value" has to be capitalized.
This also holds true for "ExpenseAccountRef::Value".
In my tests it doesn't seem to matter which comes first the "::Value"  or the "::name".
In fact, the "::name" value doesn't even need to be in the code.  Just the "::Value" code is needed.
(Intuit should allow users to comment at the bottom of each ESR entry.)

Thanks Jerel!


[0] Message Index

Go to full version