Aging Categories not being updated before invoice printing (random occurrences)

SOLVED

We are having an issue where the latest payment of a customer is not being reflected in a printed invoice. This issue only happens on very rare occasions, and we do not receive any errors or notifications before it happens.

Below are a few observations:

Our invoice report “Outstanding Balance” Section which we are having issues with is populated with data from the AR_Customer Table.  The formula that is used to calculate the “outstanding balance” is {AR_Customer.CurrentBalance}+{AR_Customer.AgingCategory1}+{AR_Customer.AgingCategory2}+{AR_Customer.AgingCategory3}+{AR_Customer.AgingCategory4}

The aging categories represent the amount still owed - broken down by days ‘past-due’ as follows:
AgingCategory1: 5 days past due
AgingCategory2: 15 days past due
AgingCategory3: 30 days past due
AgingCategory4: 60 days past due

My theory is that Sage has some kind of delay (or something is causing a delay) between when the payment is processed and when these AgingCategory fields are updated (It almost seems like the printing process itself resolves the issue). This would explain why the payment is showing up on the first printed Invoice, but the outstanding balance is not updated. One thing that seem to fit this theory is that the payments for the last two invoices for which we had this issue, were made a few days before the invoice was generated, and as soon as the invoices were reprinted, the issue was resolved.

Any Help or suggestions would be appreciated. I'd be glad to provide any other information needed to solve this issue.