Login | |
|
 |
RE: calling subroutine within subroutine, passing paren... - 7/19/2007 8:03:48 AM
|
|
 |
|
| |
DiGiTAL.SkReAM
Posts: 1184
Score: 7
Joined: 9/6/2005
From: Florida, USA
Status: offline
|
No, vbs doesn't support that kind of introspection.
_____________________________
"Would you like to touch my monkey?" - Dieter (Mike Meyers) "It is better to die like a tiger, than to live like a pussy." -Master Wong, from Balls of Fury
|
|
| |
|
|
|
 |
RE: calling subroutine within subroutine, passing paren... - 7/19/2007 8:27:05 AM
|
|
 |
|
| |
Fredledingue
Posts: 383
Score: 0
Joined: 5/9/2005
From:
Status: offline
|
Why don't you pass subRoutineName as a variable to your DisplayErr function? DisplayError (subRoutineDoesSomethingCool)
_____________________________
Fred
|
|
| |
|
|
|
 |
RE: calling subroutine within subroutine, passing paren... - 7/20/2007 10:01:13 AM
|
|
 |
|
| |
Fredledingue
Posts: 383
Score: 0
Joined: 5/9/2005
From:
Status: offline
|
quote:
ORIGINAL: Fredledingue Why don't you pass subRoutineName as a variable to your DisplayErr function? DisplayError (subRoutineDoesSomethingCool) Now, I'm thinking the above code is worng, this should be correct: DisplayError ("subRoutineDoesSomethingCool") Even worse: it could trigger your subroutine an infinite number of time! (or cause an error or some wierd effect) The subroutine name is not a special object, it's merely a text string. I don't know if there is a sub.name method so you will have to hardcode the sub name when calling the function.
< Message edited by Fredledingue -- 7/20/2007 10:04:16 AM >
_____________________________
Fred
|
|
| |
|
|
|
 |
RE: calling subroutine within subroutine, passing paren... - 7/20/2007 11:32:34 AM
|
|
 |
|
| |
DiGiTAL.SkReAM
Posts: 1184
Score: 7
Joined: 9/6/2005
From: Florida, USA
Status: offline
|
quote:
ORIGINAL: Fredledingue I don't know if there is a sub.name method so you will have to hardcode the sub name when calling the function. http://www.visualbasicscript.com/fb.aspx?m=49710
_____________________________
"Would you like to touch my monkey?" - Dieter (Mike Meyers) "It is better to die like a tiger, than to live like a pussy." -Master Wong, from Balls of Fury
|
|
| |
|
|
|
 |
RE: calling subroutine within subroutine, passing paren... - 7/20/2007 6:39:43 PM
|
|
 |
|
| |
DiGiTAL.SkReAM
Posts: 1184
Score: 7
Joined: 9/6/2005
From: Florida, USA
Status: offline
|
Sorry, I couldn't resist. I should have, but I couldn't.
_____________________________
"Would you like to touch my monkey?" - Dieter (Mike Meyers) "It is better to die like a tiger, than to live like a pussy." -Master Wong, from Balls of Fury
|
|
| |
|
|
|
|
|