Pass a variable from form code to vba macro code.

barboza

Registered User.
Local time
Today, 07:21
Joined
Aug 22, 2007
Messages
23
How can one pass a variable form form code to macro code.

StrA is a variable with the value of 8 used in the vba code of a form - frmCustody

We have a macro called Test

how can macro test run the line:

MsgBox strA

and have the value 8 appear in the message box.

Thanks,

B
 
B,

I don't use Macros, but can resist.

I know you can do it if:

1) The form is open,
2) You use MsgBox SomePublicFunction("strA")

The function can just return --> Forms!frmCustody![strA]

Wayne
 

Users who are viewing this thread

Back
Top Bottom