There are two documents - debit and credit (e.g. an invoice and a payment), the balance of the payment/credit memo is more/the same as the balance of the invoice. How to close a debit document with an existing credit one?
Only the credit documents in the status "Open" can be attached to the invoices. If there is a credit memo or payment by "Check/Cash" payment method in the "Hold" status, it is required to open the document by clicking "Release".
Attach the open payment/credit memo to the invoice:
Home> Operation Director> Account Manager> Customers> Account #ID > AR Document #ID
Applications > Apply Document button
In case the payment attached to invoice does not cover the 'Total' sum of the invoice, invoice will stay in the status "Open". You may attach other credit document (credit memo, payment) equal to the current balance of the invoice to close it.
If you need an automatic documents application, set an option "Auto Apply Credits" to "Yes" in the customer class (already created invoices are to be closed manually):