trying to do a calculation from 1 form to another form?

Jon123

Registered User.
Local time
Today, 11:19
Joined
Aug 29, 2003
Messages
668
here is the code

Code:
       If ([Frm-RPC]![dat107] - [Frm-RPC]![dat100] > 0.1) Or ([Frm-RPC]![dat107] - [Frm-RPC]![dat100] < -0.1) Then

The form is open but the form does not focus and when this runs I get an error that it cant find the control or its closed?

any help
 
ok but its not a subform its a popup form. do you determine mainform vs sub
 
This syntax from the link:

Forms!Mainform!ControlName
 
If ([Frm-RPC]![dat107] isn't that what I have here? FRM-RPC is the mainform and dat107 would be the control ?

what am I missing here
 
You're missing the "Forms!" part at the beginning.
 
same error occurs with the Forms! added
 
What is the code now? That form is open when this code runs?
 
Code:
If ([Forms!Frm-RPC]![dat108] - [Forms!Frm-RPC]![dat101] > 0.1) Or ([Forms!Frm-RPC]![dat108] - [Forms!Frm-RPlC]![dat101] < -0.1) Then

Yes the form Frm-RPC is open
 
The bracketing is goofed. Try

Forms![Frm-RPC]![dat108]
 

Users who are viewing this thread

Back
Top Bottom