Save a Background Script for future use
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-06-2018 12:31 PM
During a recent TechNow video, I noticed that one of the Developer Evangelists was able to call a Background script by entering a shortcut in the Scripts - Background window. For example 'tn1235=
This resulted in a saved background script being populated in the background script window. I have some saved background scripts that I need to copy over from a text editor manually. How do I save a background script for future use?
Thanks,
JB

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-06-2018 12:37 PM
Hmm...curious if it was just a script include? Chuck would know.
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-06-2018 12:39 PM
You could use syntax editor macros to create macros
https://docs.servicenow.com/bundle/geneva-servicenow-platform/page/script/general_scripting/reference/r_SyntaxEditorMacros.html
and fix scripts which is saved scripts that you can run in the background if you want
https://docs.servicenow.com/bundle/kingston-application-development/page/build/applications/concept/c_FixScripts.html
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-06-2018 03:16 PM
Simon,
Thank you providing the links. I tested the syntax editor macros and those work great from a client script or background script. Is there a way to call any of these from a background script?
Thanks,
JB

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-06-2018 03:19 PM
You can also store those scripts in script include and call them from Background script;
Please mark this response as correct or helpful if it assisted you with your question.