gtARReceiptAddApply
This function supplies the information to add apply details to Accounts Receivable Receipt headers. The Receipt Reference parameter must be the unique ID returned by the gtARReceipt function call.
Reference
This must be the unique identifier generated by the gtARReceipt function call. It has the format ARREC-nnn. This ensures the apply details are of the correct Receipt header and it ensures Excel creates the header information before attempting to calculate and create the receipt apply details.
Invoice
The invoice reference that the receipt is being applied to. Leave empty if the apply is related to a credit note.
Credit Note
The credit note reference that the receipt is being applied to. Leave empty if the apply is related to an invoice.
WARNING: If the receipt if being applied to a credit note, the values in the Discount, Net, and Tax fields must all be negative.
Discount
The amount of discount allowed that applies to this applied value.
Net
The net amount being applied to the specified invoice. The total amount applied to the invoice is the sum of the discount, net and tax amounts entered.
Tax
The tax amount being applied to the specified invoice.
Returns
- Ok - If there are no errors.
- Error - If there is an error.
Errors Returned
- AR Receipt header error
- Invalid AR Receipt header reference
- AR Receipt header not found
- Invoice or Credit note reference must be entered
- Invalid customer
- Invalid receipt
- Invalid invoice