Jump to content

what does ConsoleWrite do ?


jennico
 Share

Recommended Posts

ConsoleWrite in my opinion is quite good for debugging for it allows the running of the script without the stoppages caused by the msgbox function. Though it is not recommended, one could leave the the ConsoleWrite fuction in the script when compiling and no real harm would be done. The only thing to worry about is if you want to make it more secure on what your script does, you would want to remove the ConsoleWrite before compiling.

The F8 key will show or hide the output pane in SciTE. Maybe in your case it was toggled in the off position. In my testing, even when you turn it off, it will show itself again when you run a script from SciTE when pressing F5 or Alt+F5. I suspect your install was messed up, so this is why you experienced this issue. Since reinstalling SciTE corrected your issue, you should be good to go.

Link to comment
Share on other sites

You can adjust the size of the console so that you can see more just by placing your cursor on the dividing line between the output area and the code area, holding down your mouse button, and dragging the bar up or down to resize. You can also change the size of the font simply by holding down the ctrl key and using the scroll wheel on your mouse.

Errors are shown by being in red in the output box and with the AU3Check window that will be shown when an error has occurred.

Edited by Volly
Link to comment
Share on other sites

  • Developers

yes, that was my plan for today ! :) i will implement console read.

but still.... lets say you have your compilation of example scripts on your hard disk. what you would expect is: double click them and see whats happening.

instead, if you have consolewrite in the script (you can't see this before opening), nothing happens and you might come to the wrong conclusion that it does not work. u have to open it in scite first. this is not practical at all !

personally, i always have up to 20 open scripts in scite and i am glad if i don't have to open another little example scriptie in a new tab (and consequently, on hard disk).

for me, i use winsettitle if i don't want a messagebox to stop the script. or, which is very nice (gary likes to to this), ToolTip. works without gui and the message is right by your mouse.

another reason: the console is hard to read !! you have to scroll the lines to find the message, and the message is not marked or colored in any way. well, i really don't like it.

of course, it's not redundant, that was a bit exagerated, it's the wrong word. it's okay for debugging, but please, please, avoid to use it in example scripts in the forum.

j.

You seem to have strong opinions about something you only just figured out how it works.

I hardly ever used the MsgBox() debugging (ctrl+shift+d) and nearly always use Alt+D to insert the debug lines. This allows me to simply jump the the correct script line by double clicking on the Output line.

When done its a simple step to comment all debugging lines with the available Lua functions.

When a compiled script needs debugging capabilities I always add tracing to a log file which makes it pretty simple to roll out and review what happens without interfering with running of the script.

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

You seem to have strong opinions about something you only just figured out how it works.

yes, of course; thank you ! i would say, i have a strong opinion about nearly everything. :) everybody with brains should.

after having slept over this issue, i came to a final conclusion:

posting examples which contain ConsoleWrite is a bad scripting habit.

nobody should post a script that excludes a number of users from its benefits. (i especially think of users that do not use editors that support console.) and nobody should expect from the others that they execute their scripts from SciTe. Usually, i think, the majority will simply double click them.

j.

Edited by jennico
Spoiler

I actively support Wikileaks | Freedom for Julian Assange ! | Defend freedom of speech ! | Fight censorship ! | I will not silence.OixB7.jpgDon't forget this IP: 213.251.145.96

 

Link to comment
Share on other sites

  • Developers

yes, of course; thank you ! i would say, i have a strong opinion about nearly everything. :) everybody with brains should.

Don't agree: everybody with brains should think and understand first before stating their strong opinion! :)

after having slept over this issue, i came to a final conclusion:

posting examples which contain ConsoleWrite is a bad scripting habit.

... and this is bullshit as this statement is much to generic.

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

  • Moderators

yes, of course; thank you ! i would say, i have a strong opinion about nearly everything. :) everybody with brains should.

after having slept over this issue, i came to a final conclusion:

posting examples which contain ConsoleWrite is a bad scripting habit.

nobody should post a script that excludes a number of users from its benefits. (i especially think of users that do not use editors that support console.) and nobody should expect from the others that they execute their scripts from SciTe. Usually, i think, the majority will simply double click them.

j.

Your posts here are the most rediculous I've read in some time.

You're basically telling those of us "masses" that we should not work with the native tools provided to us (which make our lives (the masses) much easier).

I say to the "non-masses" (That's you), get off your ass and get with the program. And if you can't for whatever reason, quit bitching about why something shouldn't be, and write a simple script that converts the code to what you specifically wish it would be. (Would be 1 line of code using RegEx)

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

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