Skip to main content

Scripting: How to use logger.info()

Comments

1 comment

  • Tiffanie Staver
    Alex commented  ·  

    Hi Nathan,

    You can use logger.info() in several ways to validate that the script is working as designed and control the errors in the error logs when something does not work.

    For example, if you want to validate that a certain field has a value, you can write the script like this before the if() statement: logger.info(currentValues['Field Name']). This is to check that that field has a value in the first place. If you have a multi-step script, you can put a logger.info in the middle to check if the script made it that far: logger.info('Step 3 Completed) which will show "Step 3 Completed" in the error logs.

    Hope this helps!

    Alex

    0

Please sign in to leave a comment.

Powered by Zendesk