Jump to content

"Debug to MsgBox"


Recommended Posts

Most likely a SciTE bug...

$a = 0
$b = 1

Put the cursor at the start of line 2, just before "$b" and hit Ctrl-Shift-d to insert a debug MsgBox().

$a = 0
$b = 1
MsgBox(262144,'Debug line ~' & @ScriptLineNumber,'Selection:' & @lf & '
$b' & @lf & @lf & 'Return:' & @lf & 
$b) ;### Debug MSGBOX

Updated post to conform to PsaltyDS's sensible approach.

Edited by jaberwocky6669
Link to comment
Share on other sites

All you need is this to demo:

$a = 0
$b = 1

Put the cursor at the start of line 2, just before "$b" and hit Ctrl-Shift-d to insert a debug MsgBox().

;)

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Link to comment
Share on other sites

All you need is this to demo:

$a = 0
$b = 1

Put the cursor at the start of line 2, just before "$b" and hit Ctrl-Shift-d to insert a debug MsgBox().

;)

Yeah, that's a much better example. Lulz, when I was here earlier today I wasn't exactly ready for primetime.

Um, yeah, no Ok, yeah, well, I wouldn't use it for something so small. A couple of well placed print statements will do the trick.

Anyways, it isn't earth shattering just something to look out for if you use 'debug to msgbox'

Edited by jaberwocky6669
Link to comment
Share on other sites

  • Developers

Uploaded a updated AutoItTools.lua which removes any CR or LF characters from the debug statement.

Give it a try to see if that works for you too.

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

Worked for me. Output:

$a = 0
MsgBox(262144,'Debug line ~' & @ScriptLineNumber,'Selection:' & @lf & '$a' & @lf & @lf & 'Return:' & @lf & $a) ;### Debug MSGBOX
$b = 1
MsgBox(262144,'Debug line ~' & @ScriptLineNumber,'Selection:' & @lf & '$b' & @lf & @lf & 'Return:' & @lf & $b) ;### Debug MSGBOX

;)

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Link to comment
Share on other sites

Yup, works fer me!

Thanks once again Jos. I hope you didn't work too hard to fix that bug, oh lordy. Because, you know, the fate of mankind's future rested in the balance. ;)

Well gosh, since I'm on a roll. If you use Trace: Add trace lines. Save the file. And then Trace: Remove all trace lines it takes all of the blank lines with it too. I know I could just ctrl-z.

Edited by jaberwocky6669
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...