Jump to content

consolewrite extended fonctionnality, jump to file.


Recommended Posts

Hi guys ! nice to see you again !

Here it is:

In my scripts, i use several include files. (about 20).

For debugs, i would like to use ConsoleWrite('(5) : Clic pour aller à la ligne.' & @crlf  )

But it only jump in the file currently opened. ( i have about 10 au3 file opened in scite, and if i click, it jump to line 5 of the current one ). :mad:

It would have be nice to ask: ConsoleWrite('(5,awesomefile.au3) : Clic pour aller à la ligne.' & @crlf  ). Or simply it would go to the line 5 of the script where the command was.

 

Have you found a tip for that ?

 

thanks !

have fun

\,,/  Nicolas  \,,/

Link to comment
Share on other sites

  • 3 weeks later...
  • Developers

I have found this workaround .

ConsoleWrite(@ScriptDir  &  '\myfile.au3('  &  @ScriptLineNumber  &  ',1) : WARNING: '  &  @crlf )

It is much easier to load the Full SciTE4AutoIt3 version and do Alt+d on the given variable or Functions.
One caveat with your ConsoleWrite line is when the filename contains spaces or brackets.  That is why I have put double quote support around the filename in my version of SciTE, and added those to Tidy and au3check. 

ConsoleWrite('"' & @ScriptDir  &  '\myfile.au3"('  &  @ScriptLineNumber  &  ',1) : WARNING: '  &  @crlf )

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

It is much easier to load the Full SciTE4AutoIt3 version and do Alt+d on the given variable or Functions.

@Jos     I like the Alt+d    Question: Is it possible to add the @extended value to the consolewrite? Where to alter the property file?
 

App: Au3toCmd              UDF: _SingleScript()                             

Link to comment
Share on other sites

  • Developers

These are the defaults defined in au3.properties:

## Debug Output Options (to permanent change your selection copy them to SciTEUser.Properties and change it there
# Debug MessageBox Option 2="All"  1="No @extended"   0="No @extended & @error".
debug.msgbox.option=0
# Debug Console Option    3="All"  2="No SystemTime"  1="No SystemTime & Return"  0="No SystemTime, Return & Error".
debug.console.option=1
# Debug Trace Option      3="All"  2="No SystemTime"  1="No SystemTime & Return"  0="No SystemTime, Return & Error".
debug.trace.option=1
# extra propery used by AutoItAutoComplete.LUA to totally disable AutoComplete when set to 1

So just copy this line and put that in your SciTEUser.properties:

# Debug Console Option    3="All"  2="No SystemTime"  1="No SystemTime & Return"  0="No SystemTime, Return & Error".
debug.console.option=3

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

Hi

ALD+D is not useful if you have many files, and the consolewrite is in a file that is not the main .

when I do ALD+d ( and im using the full SciTE4AutoIt3  version) I get

ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $hFile= ' & $hFile& @crlf ) 

the script name is not added, and even if I edit the properties file, to add @scriptdir or  @ScriptFullPath    is the main au3 file  that the script runs.

correct me if im wrong

thanks

Link to comment
Share on other sites

  • Developers

Correct, it's intent is to do debugging and doesn't add file info as that is not needed in most cases.
You are welcome to make any modifications you want personally. ;)

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

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

×
×
  • Create New...