Jump to content

See all variables used and their values.


 Share

Recommended Posts

Is there any code I can put into my script which displays all variables and their values in order of declaration?

For example:

$var1 = 5

$var2 = 3

$var3 = $var1 + $var2

Would give you:

$var1 = 5

$var2 = 3

$var3 = 8

Just thought it would be a time saver.

Edited by T0M50N
Link to comment
Share on other sites

I don't think you can automatically.  I suppose you could call a function

Local $var = 1
_DisplayVars("$var", $var)

Local $var2 = 55
_DisplayVars("$var2", $var2)

Local $var3 = 125
_DisplayVars("$var3", $var3)


Func _DisplayVars($Variable, $Value)
    ConsoleWrite($Variable & " = " & $Value & @LF)
EndFunc

EVERY time you declare and assign.

or

Local $var = 1
ConsoleWrite("$var = " & $var & @LF)

Local $var2 = 55
ConsoleWrite("$var2 = " & $var2 & @LF)

Local $var3 = 125
ConsoleWrite("$var3 = " & $var4 & @LF)
Edited by NewPlaza
Link to comment
Share on other sites

search for "AutoIt Debugger":

Signature - my forum contributions:

Spoiler

UDF:

LFN - support for long file names (over 260 characters)

InputImpose - impose valid characters in an input control

TimeConvert - convert UTC to/from local time and/or reformat the string representation

AMF - accept multiple files from Windows Explorer context menu

DateDuration -  literal description of the difference between given dates

Apps:

Touch - set the "modified" timestamp of a file to current time

Show For Files - tray menu to show/hide files extensions, hidden & system files, and selection checkboxes

SPDiff - Single-Pane Text Diff

 

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...