IR Framework

logger.LEVEL Constants

Contains the constant values for the log level of a logger object.
object.trace(message)
object.debug(message)
object.info(message)
object.warn(message)
object.error(message)
object.fatal(message)

Arguments

object
Required. Always the name of a logger object.


message
Required. The information to send to the log.



Remarks

Logging methods that succeed write the current date, current time, user name, computer name, application type, document type, document url, and a message to the log file.
condition return value
message or message.toString() is not a string 3
An empty log entry is written.
Logger level is greater than logger method level 1
No log entry is written.
Logger level is less than or equal to the logger method level and message is valid. 0
A log entry is written.
An unhandled error occurred. 4
The following example illustrates the use of the LEVEL constants.

//	create a logger and set the level to DEBUG and write entries to the Console window
var myLogger = new Application.logger();
myLogger.Level(myLogger.LEVEL.DEBUG);

myLogger.trace("trace");	//	TRACE is lower than DEBUG, so this won't do anything
myLogger.debug("debug");
myLogger.error("error");


//	make the logger write entries to My Documents\mylog.log
myLogger.Target("mylog.log");

var a = myLogger.trace("trace");	//	returns 1
var b = myLogger.debug("debug");	//	returns 0
myLogger.error("error");


Applies To:

logger Object



Requirements