Is there a way to find what script I am currently running?

Is there a way to find what script I am currently running?

Post by Daniel Arm » Sat, 18 Apr 2009 16:32:01


I would like for some of my scripts to be able to tell me things about themselves, like where they are and what they are called. Is there a way to do this other than throwing an exception and extracting the stacktrace?

Sincerely
Daniel Armyr
 
 
 

Is there a way to find what script I am currently running?

Post by Jos » Sat, 18 Apr 2009 18:10:03


See MFILENAME. You might also be interested in DBSTACK and other debugging functions.

hth
Jos