Hello,
Here is what trouble me :
In a standard module, I need to test an long field.
Public function test_Idx (Inref as Long) as Long
Dim stDocname as string
Dim T_idx as long
stDocname = "Edit_Form"
DoCmd.Openform stDocname,,,"[Ref_ctc]=" & Inref
So the form opens only where I want it to be tested. So far so good. Now I want to test [R_Idx], a long, and can't figure out how to get it :
- Me method does not work as it's a standard module.
I've tried :
T_idx = R_Idx
T_idx =stDocname.[R_Idx]
both gives me invalid qualifier errors which is understandable
But should I use the formal declaration :
T_idx = Forms!["Edit_Form"].[R_Idx]
I get a unable to find "Edit_Form" form and thus cannot proceed.
Can anyone please tell me what I do wrong?.
Here is what trouble me :
In a standard module, I need to test an long field.
Public function test_Idx (Inref as Long) as Long
Dim stDocname as string
Dim T_idx as long
stDocname = "Edit_Form"
DoCmd.Openform stDocname,,,"[Ref_ctc]=" & Inref
So the form opens only where I want it to be tested. So far so good. Now I want to test [R_Idx], a long, and can't figure out how to get it :
- Me method does not work as it's a standard module.
I've tried :
T_idx = R_Idx
T_idx =stDocname.[R_Idx]
both gives me invalid qualifier errors which is understandable
But should I use the formal declaration :
T_idx = Forms!["Edit_Form"].[R_Idx]
I get a unable to find "Edit_Form" form and thus cannot proceed.
Can anyone please tell me what I do wrong?.