Re: Where do the errors go?
Re: Where do the errors go?
- Subject: Re: Where do the errors go?
- From: Christopher Stone <email@hidden>
- Date: Fri, 11 May 2018 00:09:39 -0500
On 05/10/2018, at 13:10, Gil Dawson <email@hidden
<mailto:email@hidden>> wrote:
> ...but I cannot figure out how to tell Console to display debugging messages.
> Using the filter "applet", I scanned down some of the logs listed in the
> left windowpane. I found a few entries that contained "applet", but none had
> the text of the diagnostic messages.
Hey Gil,
Axel is logging to a specific file on the Desktop:
~/Desktop/TestLog.txt
You'd need to open that file in the Console to see any logged events.
If you prefer to use the normal Console log you'd do something like this:
-------------------------------------------------------------
# Auth: Christopher Stone { Heavy Lifting by Shane Stanley }
# dCre: 2016/07/25 15:47
# dMod: 2018/05/10 23:59
# Appl: AppleScriptObjC
# Task: Log Text to Console
# Aojc: True
# Libs: None
# Osax: None
# Tags: @Applescript, @Script, @ASObjC, @Log, @Console
-------------------------------------------------------------
use AppleScript
use framework "AppKit"
-------------------------------------------------------------
set textToLog to "This text will be logged to Console.app"
its logText(textToLog)
-------------------------------------------------------------
--ยป HANDLERS
-------------------------------------------------------------
on logText(theText)
current application's NSLog("%@", theText)
end logText
-------------------------------------------------------------
--
Take Care,
Chris
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden