Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Calling a sub method
Hi, I have the name of my sub method stored in a variable: mySubMethodName = "do_something" I then want to call this method using the variable, I have tried the following but it doesn't work: Call mySubMethodName Is there anyway to do what I am trying to do? -- richcoleuk ------------------------------------------------------------------------ richcoleuk's Profile: http://www.excelforum.com/member.php...o&userid=33103 View this thread: http://www.excelforum.com/showthread...hreadid=549375 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Calling a sub method
richcoleuk wrote: Hi, I have the name of my sub method stored in a variable: mySubMethodName = "do_something" I then want to call this method using the variable, I have tried the following but it doesn't work: Call mySubMethodName Is there anyway to do what I am trying to do? -- richcoleuk ------------------------------------------------------------------------ richcoleuk's Profile: http://www.excelforum.com/member.php...o&userid=33103 View this thread: http://www.excelforum.com/showthread...hreadid=549375 Why don't you just use Call do_something Christian |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Calling a sub method
because the name of the sub method is specified on the worksheet, and this value is taken from the sheet. -- richcoleuk ------------------------------------------------------------------------ richcoleuk's Profile: http://www.excelforum.com/member.php...o&userid=33103 View this thread: http://www.excelforum.com/showthread...hreadid=549375 |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Calling a sub method
richcoleuk,
Application.Run ? NickHK "richcoleuk" wrote in message ... Hi, I have the name of my sub method stored in a variable: mySubMethodName = "do_something" I then want to call this method using the variable, I have tried the following but it doesn't work: Call mySubMethodName Is there anyway to do what I am trying to do? -- richcoleuk ------------------------------------------------------------------------ richcoleuk's Profile: http://www.excelforum.com/member.php...o&userid=33103 View this thread: http://www.excelforum.com/showthread...hreadid=549375 |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Calling a sub method
Application.Run variable_name
-- HTH Bob Phillips (replace somewhere in email address with gmail if mailing direct) "richcoleuk" wrote in message ... because the name of the sub method is specified on the worksheet, and this value is taken from the sheet. -- richcoleuk ------------------------------------------------------------------------ richcoleuk's Profile: http://www.excelforum.com/member.php...o&userid=33103 View this thread: http://www.excelforum.com/showthread...hreadid=549375 |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Calling a sub method
Works a charm, thanks Nic -- richcoleu ----------------------------------------------------------------------- richcoleuk's Profile: http://www.excelforum.com/member.php...fo&userid=3310 View this thread: http://www.excelforum.com/showthread.php?threadid=54937 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Please post this thread a correct full method, method about | New Users to Excel | |||
Please post this thread a complete correct method, method about te | New Users to Excel | |||
Calling Excel/Opentext method via ActiveX in a service application | Excel Programming | |||
Calling from C#.Net App Office._CommandBarButton.Execute() method in Excel 2003 throws a COMException | Excel Programming | |||
Calling a module function from a class method | Excel Programming |