Author Topic: VendorCreditQuery; Remainig Balance  (Read 1200 times)

trebor

  • Member
  • *
  • Posts: 57
VendorCreditQuery; Remainig Balance
« on: September 19, 2014, 12:17:01 PM »
It is not an issue with remaining balance at all, the whole credit is applied to one BillPayment, as long as it is larger.  You cannot apply a a part of a vendorcredit, you apply the whole amount.

Never mind

« Last Edit: September 19, 2014, 01:45:02 PM by trebor »

Geoffrey Gerhard

  • Guru
  • Member
  • ****
  • Posts: 468
Re: VendorCreditQuery; Remainig Balance
« Reply #1 on: September 19, 2014, 02:06:07 PM »
I missed the original version of this post, but it's worth mentioning that a VendorCredit may be unapplied, partially applied, or fully applied. Although the OSR identifies OpenAmount as an element of VendorCredit, it does not return the expected value and so cannot be used to determine how much of the VendorCredit is unapplied.

It's possible--but tricky--to derive the amount of the Vendor Credit that has been applied and subtract that amount from the value of the CreditAmount element.

HTH!

Geoffrey Gerhard
Creative Solutions Incorporated
14000 Creekside Drive
Matthews, NC  28105
704) 814-6852

trebor

  • Member
  • *
  • Posts: 57
Re: VendorCreditQuery; Remainig Balance
« Reply #2 on: September 26, 2014, 06:51:37 AM »
That was kind of it, but I have a bigger question......

Can one credit be applied to multiple bills?  I am not sure how that is done.  Do I apply up to the amount of the bill (or a dollar or two less), subtract from the credit balance, then continue applying the balance until I run out of bills?

Basically there are situations where the credit is larger than any one bill, but I could distribute the credit across multiple bills.



« Last Edit: September 26, 2014, 07:12:44 AM by trebor »

Geoffrey Gerhard

  • Guru
  • Member
  • ****
  • Posts: 468
Re: VendorCreditQuery; Remainig Balance
« Reply #3 on: September 26, 2014, 10:26:50 AM »
A BillPaymentCheckAdd Request allows you to apply one or more credits to one or more Bills. Look at the BillPaymentCheckAdd's AppliedToTxnAdd node in the OSR for details. You need to know the TxnID of each Bill you want to pay, and the TxnID of each VendorCredit ( called a Bill Credit in the QBUI ) you want to apply.

If you omit all PaymentAmount elements in the Request ( so the transaction is only DiscountAmount and SetCredit::AppliedAmount values ) the check amount will be $0.00 and you might want to set the IsToBePrinted element's value to False.

Geoffrey Gerhard
Creative Solutions Incorporated
14000 Creekside Drive
Matthews, NC  28105
704) 814-6852