call a sub using a variable
- From: "smk23" <smk23@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 27 Jun 2005 15:46:03 -0700
I need to change which subroutine I call based on the user's input. Can I
save the name of the Sub in a variable? So far I've tried:
Dim MySub as string
MySub = "sLoadSNData"
Call MySub
No surprise this complains that "expected procedure, not variable". So
what's the syntax or best way to dynamically vary the subroutine called?
Thanks so much!
--
sam
.
- Follow-Ups:
- Re: call a sub using a variable
- From: Dirk Goldgar
- Re: call a sub using a variable
- From: RuralGuy
- Re: call a sub using a variable
- From: Brendan Reynolds
- Re: call a sub using a variable
- Prev by Date: Returning multiple records
- Next by Date: Re: Search and Listbox
- Previous by thread: Returning multiple records
- Next by thread: Re: call a sub using a variable
- Index(es):
Relevant Pages
|