Modules

filter

 

Objects/Functions

module (N/log)

SuiteScript 2.0

log.error(options)

{log}.error({title: {string*},details: {any}})

N/log Module
log.error()
Method Description: Logs an Error message. Error messages appear on the Execution tab only if the Log Level on the script deployment is set to Audit, Debug, or Error. Use this method for scripts in production.
Returns: void
Supported Script Types: All script types For more information, see SuiteScript 2.0 Script Types.
Governance: Amount of logging in any 60 minute period is limited. See N/log Module Guidelines.
Module: N/log Module
Since: 2016.1
Search NetSuite - https://system.netsuite.com/app/help/helpcenter.nl?search=log.error(options)

Example:

// Code Example 1
//Add additional code
//...
var myValue = 'value';
log.error({
title: 'Error Entry',
details: 'Value of myValue is: ' + myValue
});
//...
//Add additional code

//SOURCE: https://system.netsuite.com/app/help/helpcenter.nl?fid=section_4430385812.html