try BadlyCodedFunc() catch e MsgBox % "Error in " e.What ", which was called at line " e.Line BadlyCodedFunc() { throw Exception("Fail", -1) }

AutoHotkey_L v1.1.05.05
Started by
Lexikos
, Oct 08 2011 05:44 AM
30 replies to this topic
I've just started playing around with try catch Exception() and I noticed with the example if I run it out of SciTE then e.Line shows the correct line. But when compiled I can't seem to guess how to adjust e.Line to account form some difference introduced by the compilation. If I account for commented and blank lines I can get A_LineNumber to correlate, but e.Line doesn't seem to play by the same rules.
#31
-
Posted 01 April 2012 - 11:28 PM

"Some people, when confronted with a problem, think I know, I'll use regular expressions. Now they have two problems."
- Jamie Zawinski