Here is some example code and the setup data required:
PayeeEntityRefListID = 'C0000-933272656' (Required) BankAccountRefListID = '20000-933270541' (Required) IsToBePrinted = 1 (Either this one or RefNumber is required) AppliedToTxnTxnID = '2F78-1071505657','976-933373192','A2D-933373874', (Find from Bill Table) AppliedToTxnPaymentAmount = 200.75 (Necessary) AppliedToTxnSetCreditCreditTxnID = '5522-1197768491' (Find from VendorCredit Table) AppliedToTxnSetCreditAppliedAmount = 10.00 TxnDate = 2007-12-15
TO PAY A BILL INSERT INTO BillPaymentCheckLine (PayeeEntityRefListID, BankAccountRefListID, IsToBePrinted, AppliedToTxnTxnID, AppliedToTxnPaymentAmount, TxnDate, FQSaveToCache) Values ('C0000-933272656', '20000-933270541', 1, '2F78-1071505657', 200.75, {d'2007-12-15'}, 0)
TO APPLY A CREDIT INSERT INTO BillPaymentCheckLine (PayeeEntityRefListID, BankAccountRefListID, IsToBePrinted, AppliedToTxnTxnID, AppliedToTxnPaymentAmount, AppliedToTxnSetCreditCreditTxnID, AppliedToTxnSetCreditAppliedAmount, TxnDate,FQSaveToCache) Values ('C0000-933272656', '20000-933270541', 1, '2F78-1071505657', 200.75, '5522-1197768491', 10.00, {d'2007-12-15'}, 0)
For more detailed examples see: How can I apply check payments or credits to bills? |