CallersLine Function |
Syntax:
CallersLine[(Depth)]
Group:
Description: Returns the caller's line as a text string. The text format is: "[macroname|subname#linenum] linetext".
Parameters
Parameter |
Description |
This integer value indicates how deep into the stack to get the caller's line. If Depth = -1 then return the current line. If Depth = 0 then return the calling subroutine's current line, etc.. If Depth is greater than or equal to the call stack depth then a null string is returned. If this value is omitted then the depth is 0. |
Example:
Sub A
Debug.Print CallersLine '"[(untitled 1)|Main# 2] A"
EndSub