PearlGI
Registered User.
- Local time
- Today, 09:58
- Joined
- Aug 30, 2001
- Messages
- 125
This isn't as straightforward as the title suggests!
Does anyone know of a way to call a procedure by using a variable that contains the procedure name rather just typing the procedure name into the code.
For example, if I wish to run a procedure called 'Calc', usually you would just type
Calc
into the code and the procedure would run, however in my situation I don't know the name of the procedure, this is to be passed to the code as a parameter. Therefore, I'm looking for something like
strCode = "Calc"
...
...
RunCode strCode
I've tried looking at the DoCmd functions, but DoCmd.OpenModule just displays the code and doesn't run it.
Any suggestions?
Does anyone know of a way to call a procedure by using a variable that contains the procedure name rather just typing the procedure name into the code.
For example, if I wish to run a procedure called 'Calc', usually you would just type
Calc
into the code and the procedure would run, however in my situation I don't know the name of the procedure, this is to be passed to the code as a parameter. Therefore, I'm looking for something like
strCode = "Calc"
...
...
RunCode strCode
I've tried looking at the DoCmd functions, but DoCmd.OpenModule just displays the code and doesn't run it.
Any suggestions?