On Tue, 13 Jul 2010 14:18:05 -0400, Ron Rosenfeld <(E-Mail Removed)> wrote:
>On Tue, 13 Jul 2010 13:43:35 -0400, (E-Mail Removed) wrote:
>
>>If I detect an error in a Sub/Function, I would like to be able to print
>>the sequence of callers. Line numbers would be great too if that is
>>possible.
>>
>>Example:
>>
>>sub Main()
>> call Sub
>>end sub
>>
>>sub Sub1()
>> call sub2(3)
>>end sub
>>
>>Sub Sub2(n as long)
>> if n > 2 then
>> 'Code to print
>> ' Sub 2 called with value n
>> ' from Sub1 at line 2
>> ' from Main at line 2
>> end
>> end if
>>end sub
>
>Check out the UserName property of the Application object.
Apparently I am not understanding your reply. Application.UserName returns
the name of my computer, not the names in the sub/functuion call chain.