rmckay Posted December 12, 2019 Posted December 12, 2019 Hello, I've added ConsoleWrite lines to functions I've created. The format for the ConsolWrite statements is : (@CRLF & $sPath & '(' & @ScriptLineNumber & ') : *** Func _ABC() ***: ' & @crlf ). $sPath is defined as the filepath to the file containing the function - Local $sPath = "C:\Users\Owner\Documents\AutoIt\NT8 Download Replay Data\DownloadReplayFunctions02.au3" Local $sPath = "C:\Users\Owner\Documents\AutoIt\NT8 Download Replay Data\DownloadReplayFunctions02.au3" ConsoleWrite(@CRLF & $sPath & '(' & @ScriptLineNumber & ') : *** Func _oMenuItemHistoricalData() ***: ' & @crlf ) The result is that I can access the functions from the Scite output window when the function is located in another file which is included in the main file. For some reason Scite adds a line to the code when I switch to the Include file from the output window. Why does the line get added to the script and can I stop if from appearing? Thanks,
Danp2 Posted December 12, 2019 Posted December 12, 2019 Looks like you haven't completed the function with the EndFunc statement. Have you tried adding that? Latest Webdriver UDF Release Webdriver Wiki FAQs
rmckay Posted December 12, 2019 Author Posted December 12, 2019 Hi @Danp2 The function is complete and works when called. The EndFunc is several lines below . Also, I forgot to mention that each of the 20+ functions I've written, which are in 2 different files, has that same line added.
Developers Jos Posted December 12, 2019 Developers Posted December 12, 2019 47 minutes ago, rmckay said: Why does the line get added to the script and can I stop if from appearing? This is because The SciTE error lexer thinks that this SciTEoutput line is and error and will show them as such with with inline errors enabled. 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.
rmckay Posted December 12, 2019 Author Posted December 12, 2019 Hi @Jos I'm not familiar with the Scite error lexer. Can I enable/disable the "inline errors" and if so is there a downside to disabling them? Thanks
Developers Jos Posted December 12, 2019 Developers Posted December 12, 2019 (edited) 19 minutes ago, rmckay said: Can I enable/disable the "inline errors Sometimes I wonder why I made the helpfile... : Quote error.inline style.error.0 style.error.1 style.error.2 style.error.3 To see error messages interspersed with the source code, set error.inline=1. Different visual styles are used for different severities: style.error.0 is the default; style.error.1 for warnings; style.error.2 for errors; and style.error.3 for fatal errors. The severity of a message is inferred from finding the text "warning", "error", or "fatal" in the message. .. but first things first: when I run the provided example, I do not get the line added, only when clicking it, it will jump to it and put a yellow maker in front. Do you see the same with that example: Local $sPath = "C:\Users\Owner\Documents\AutoIt\NT8 Download Replay Data\DownloadReplayFunctions02.au3" ConsoleWrite(@CRLF & $sPath & '(' & @ScriptLineNumber & ') : *** Func _oMenuItemHistoricalData() ***: ' & @crlf ) As far as I remember it will only add these inline error markers for lines that contain " : error:" or ": warning:". Jos Edited December 12, 2019 by 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.
RTFC Posted December 12, 2019 Posted December 12, 2019 35 minutes ago, Jos said: I wonder why I made the helpfile... If it's any consolation, at the other end of the spectrum are freaks like myself, who tend to (speed)read an entire Help file to get a sense of the scope, modus operandi, and perhaps unsuspected capabilities of a particular piece of software. Having written large Help files myself (and even recorded a series of tutorial videos once), I do commiserate though. Perhaps you can glean some comfort from the fact that your digital footprint will probably outlast any physical one you leave on this Earth... seadoggie01, Jos, argumentum and 1 other 4 My Contributions and Wrappers Spoiler BitMaskSudokuSolver BuildPartitionTable CodeCrypter CodeScanner DigitalDisplay Eigen4AutoIt FAT Suite HighMem MetaCodeFileLibrary OSgrid Pool RdRand SecondDesktop SimulatedAnnealing Xbase I/O
rmckay Posted December 13, 2019 Author Posted December 13, 2019 @Jos Your help files are great. I can't believe the effort you've put in to create them. Thanks for all the hard work. The problem is that I wasn't smart enough to do a search for the right topic🤥 21 hours ago, Jos said: I do not get the line added, only when clicking it, it will jump to it and put a yellow maker in front. Yes, I get the same result. If I start the main script and the open the #include file with the functions the error doesn't show and there's no yellow marker. When I click on the link the yellow marker appears and all of the functions with a link have an error line appear. Thanks @RTFC I thought I went through all of the help topics but I only vaguely remember even seeing the error line subject, let alone any details. I think my focus need to be fixed😉 Thanks
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now