Charles...  I gave your suggestion a try but I get the same result.
Earlier, I also tried defining vAMT_OWED = SUM amt_owed from invoice WHERE
cust# = .vcu_no.  That did not work either.

John

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Charles Parks
Sent: Thursday, August 19, 2004 2:33 PM
To: RBG7-L Mailing List
Subject: [RBG7-L] - RE: Variables recalc in forms

How is   vAMT_OWED defined in the variable section of the form?

Try vAMT_OWED =  .vAMT_OWED

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of John
Engwer
Posted At: Thursday, August 19, 2004 12:14 PM
Posted To: RB7-L
Conversation: [RBG7-L] - Variables recalc in forms
Subject: [RBG7-L] - Variables recalc in forms


I am still having great difficulty getting my variables to update
properly in forms.  Here is what I am doing:

I have a form with a main table is called customer that is used to edit
customer information and display the customers purchase history in a
DBGrid from the purchase table.
The form name is puredit1
Form is set as one - many
I have a variable called vAMT_OWED that I want to display the amount
that the customer owes.
I am using the following EEP to perform the calculation

SET VAR vamt_owed = 0
COMPUTE vamt_owed AS SUM amt_owed from invoice WHERE cust# = .vcu_no
Property TABLE puredit1 'REFRESH'
recalc variables
RETURN

I have traced the EEP and it calculates the correct amount and puts it
into the var  vAMT_OWED

I currently have the EEP triggering on entry to the customer name field
in the customer table.  I have tried it "on entry to" of various fields
on the form.
Sometime when I click on the .vAMT_OWED field, the field will update
properly.

Does anyone have an idea as to what I may be doing wrong?

John

Reply via email to