Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Beginner
2 Views

Accessing variable inside subroutine

I know it is possible to access a variable inside a module using the following syntax

MODULENAME::VariableName

i.e adding a watch throught the command window in VS would read Debug.AddWatch MODULENAME::VariableName. 

However is it possible to access a variable defined/declared inside a subroutine which in turn is inside a module? For instance

MODULENAME::SubroutineName::VariableInsideSubroutineName

I already tried the above syntax but it doesn't work. Is there an alternate syntax to accomplish this? 

0 Kudos
1 Reply
Highlighted
Valued Contributor II
2 Views

No, that is only possible if

No, that is only possible if the subroutine is actually active. Otherwise the variable may not even exist. I am not aware of any syntax that makes you access SAVEd variables - they would be persistent, so in principle it ought to be possible to access them.

0 Kudos