User Tools

Site Tools


dictionary:human:writelog

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
dictionary:human:writelog [2017/10/20 16:58] – added filter parameter James Sentmandictionary:human:writelog [2023/02/13 14:52] (current) – external edit 127.0.0.1
Line 8: Line 8:
 **color** (black/blue/green/red/none)\\ **color** (black/blue/green/red/none)\\
 none will write to the log file but will not display in the log window\\ none will write to the log file but will not display in the log window\\
 +\\
 +**background color** (html color string) optional. If included the background of the line will be colored this color. Sometimes easier to see a specific message with a custom colored background. (added in v9.3.7)\\
 \\ \\
 In addition to the program provided colors listed above if you pass a string containing an RGB or web color that will be used to color the text line in the window and the log line in the file if you are saving the log file as an RTF file.\\ In addition to the program provided colors listed above if you pass a string containing an RGB or web color that will be used to color the text line in the window and the log line in the file if you are saving the log file as an RTF file.\\
Line 15: Line 17:
 **to** if you specify a file reference here the log line will also be appended to the file specified. Use this to create special logs of just the info you’re interested in or write specific info to different places.\\ **to** if you specify a file reference here the log line will also be appended to the file specified. Use this to create special logs of just the info you’re interested in or write specific info to different places.\\
 \\ \\
-**always showing** if you include “with always showing” it will show in all log windows regardless of the display or filter settings.+**always showing** if you include “with always showing” it will show in all log windows regardless of the display or filter settings.\\
 \\ \\
 **filter** (string) optional. If included then a filter option for the Log Window will be available to filter the log based on this text. Good for quickly showing just exactly the log lines you’re interested in. (added in v9.3.7) **filter** (string) optional. If included then a filter option for the Log Window will be available to filter the log based on this text. Good for quickly showing just exactly the log lines you’re interested in. (added in v9.3.7)
Line 29: Line 31:
 set myFile to ((path to desktop folder) as text) & “mySpecialLog.txt” set myFile to ((path to desktop folder) as text) & “mySpecialLog.txt”
 write log “this is my special log file” to myFile write log “this is my special log file” to myFile
-</code> 
  
 +write log “this will be filterable” filter “my filter"
 +</code>
 ===NOTE=== ===NOTE===
 when writing to a separate log file it will be up to you to manage and roll these files as appropriate and make sure you’re not writing so much that you fill your hard drive and cause other problems. No rolling or file management is performed on special files at all. when writing to a separate log file it will be up to you to manage and roll these files as appropriate and make sure you’re not writing so much that you fill your hard drive and cause other problems. No rolling or file management is performed on special files at all.
Line 36: Line 39:
 ===History:== ===History:==
 version 9.1 added support for the “always showing” parameter\\ version 9.1 added support for the “always showing” parameter\\
-version 9.3.7 added support for the “filter” parameter+version 9.3.7 added support for the “filter” parameter\\ 
 +version 9.3.7 added support for the “background color” parameter
dictionary/human/writelog.1508518728.txt.gz · Last modified: 2023/02/13 14:51 (external edit)