AHK V2: Is there a way to get full CallStack in script instead of just for current thread?

Discuss the future of the AutoHotkey language
SAbboushi
Posts: 252
Joined: 08 Dec 2014, 22:13

AHK V2: Is there a way to get full CallStack in script instead of just for current thread?

02 Aug 2018, 12:23

I'm looking to get (in script) something like what a debugger provides, but as far as I can tell, using Exception object only returns Callstack info for the current thread:

Code: Select all

    SciTE4AutoHotkey Callstack:
    
      Script filename	Line	Stack entry
      ---------------   ----    -------------------
      GetCallStack.ahk  71	    GetCallStack()          <-- Exception("", -1).line = 106
      gar2.ahk	        106	    MsgBox3()               <-- Exception("", -2).line = 85
      gar2.ahk	        106	    Timer thread
      gar2.ahk	        85	    MsgBox()
      gar2.ahk	        85	    MsgBox1()
      gar2.ahk	        83	    Timer thread
      gar2.ahk	        68	    MsgBox()
      gar2.ahk	        68  	Auto-execute thread
lexikos
Posts: 9583
Joined: 30 Sep 2013, 04:07
Contact:

Re: AHK V2: Is there a way to get full CallStack in script instead of just for current thread?

02 Aug 2018, 16:41

Not for the script's own call stack. The DBGp client can, and DBGp clients can be written in script, but must be separate to the script being debugged.

Return to “AutoHotkey Development”

Who is online

Users browsing this forum: No registered users and 25 guests