"smk23" <(E-Mail Removed)> wrote in message
news:146F73CA-543E-42A1-9CBD-(E-Mail Removed)
> Dirk, it says it can't find the procedure, which is in the the same
> form module that I used Application.Run MySub in. I tried changing it
> (MySub) to Public which didn't help.
> Thanks!
If you mentioned before that this procedure is in a form module, I
didn't see it. I assumed it was in a standard module. I don't think
Application.Run will work with a procedure in a form module, even if
that procedure it Public. If you can't move the procedure to a standard
module, then I think Brendan's idea of CallByName is probably the way to
go.
If you want to move the proc to a standard module, but are having
trouble with references to "Me", consider using Screen.ActiveForm to get
a reference to the form in question. Screen.ActiveControl will give you
the name of the control with the focus, too.
--
Dirk Goldgar, MS Access MVP
www.datagnostics.com
(please reply to the newsgroup)