Eval Question

T

Turner

I am trying to call a function using a variable. I
attempted the following code but I am getting an error:

"2425 The expression you entered has a function name that
Microsoft Access cann't find".

Public Function myStuff()

Dim stMsg As String
stMsg = "MyMsg()"

Eval (stMsg)

End Function

Public Function MyMsg()

msgbox "I am here"

End Function

Thanks!!
 
K

ka

Hi,

I copied your code directly into an Access module and tried, it works on my
side....
Could it be your Ms Access installation?

Try on another computer.

Cheers

ka
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top