jayclifford
Registered User.
- Local time
- Today, 00:01
- Joined
- Jul 23, 2013
- Messages
- 16
I want to make a Form name public to all procedures in a module (maybe all modules), without repeating the Dim statement or its name.
I envisioned the code to look something like:
Then all uses of Fr1 would refer to the Form "Form_Name_Form1" anywhere in the module.
Questions:
Does this Function have to go in the Declarations section of the Module or can it go anywhere in the Procedures section?
Excuse my ignorance, but how do I get into the Declarations section of a Module to add code?
Can it go in a Form Module or a Class Module?
Please excuse my naming conventions.
Jay
I envisioned the code to look something like:
Code:
Public Function SetVar1
Dim Fr1 as String
Set Fr1 = "Form_Name_Form1" 'This Form is based on a Query
End Function
Questions:
Does this Function have to go in the Declarations section of the Module or can it go anywhere in the Procedures section?
Excuse my ignorance, but how do I get into the Declarations section of a Module to add code?
Can it go in a Form Module or a Class Module?
Please excuse my naming conventions.
Jay
Last edited by a moderator: