Skip to Main Content
Mastering ServiceNow Scripting
book

Mastering ServiceNow Scripting

by Andrew Kindred
February 2018
Intermediate to advanced content levelIntermediate to advanced
226 pages
5h 13m
English
Packt Publishing
Content preview from Mastering ServiceNow Scripting

Script examples

The advanced server-side techniques we have seen can be used in a number of ways, and you will find advanced server-side scripting to be some of the most common in the ServiceNow platform.

Now that we have seen where to write our advanced server-side code, we can have a look at some further examples to solidify our understanding.

Let's have a look at a script include example first. We will write a script to return the active tasks of a requested item. This can be helpful for letting users know which tasks need to be completed for an item to be fulfilled.

First we will take a look at the script include code:

var item_utils = Class.create();item_utils.prototype = {    initialize: function() {    },   getActiveTasks: function getActiveTasks(item) ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

PowerShell Cookbook, 4th Edition

PowerShell Cookbook, 4th Edition

Lee Holmes
Learning Splunk

Learning Splunk

Tom Kopchak

Publisher Resources

ISBN: 9781788627092Supplemental Content