Call a function where function name is a string
Posted on 2002-03-25
I want to be able to call functions. The names are stored in a table. I am looking up the name in the table using a dlookup. When I get the name of the function, I try to call the function but it does not work. I am using the Eval Function. Code looks like this
dim strProgramCall as string
strProgramCall = Nz(DLookup("[ProgramCall]", "Report List", "[Report ID] = " & Me.Selected_Report), "None")
Error message says Run-time Error 2482 Clone Can't find the name 'NameOfFunction' you entered in the expression.
Yes, there is a function that is called NameOfFunction.
Can I call a function this way? What am I doing wrong?