Hi guys.
I have an orders form with a subform containing each item on the order.
An item has a price and a quantity.
On the footer of the subform is a field called txt_order_total which calculates sum([quantity]*[price]).
On the main form is a unbound text control that displays the order total as well as a hidden form containing the customer's credit limit.
I am trying to check that the order total does not exceed the customer's credit limit and am trying to run this check on the main form's onCurrent event.
However, this isn't working because there's a lag between when the form/record opens/is loaded and the calculation is completed. It takes a good 1-2 seconds for the calculated total to appear, and so running my check onCurrent performs its action before the calculation has finished.
Is there another way to do this or is there another onEvent I should be using?
I have an orders form with a subform containing each item on the order.
An item has a price and a quantity.
On the footer of the subform is a field called txt_order_total which calculates sum([quantity]*[price]).
On the main form is a unbound text control that displays the order total as well as a hidden form containing the customer's credit limit.
I am trying to check that the order total does not exceed the customer's credit limit and am trying to run this check on the main form's onCurrent event.
However, this isn't working because there's a lag between when the form/record opens/is loaded and the calculation is completed. It takes a good 1-2 seconds for the calculated total to appear, and so running my check onCurrent performs its action before the calculation has finished.
Is there another way to do this or is there another onEvent I should be using?