- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-30-2016 09:31 AM
I know this has to be really easy, but I don't know how:
In my UI Action script I'm doing a "action.setRedirectURL('<URL literal>');" and it works fine - it takes the user where I want them to go. But when they finish on the new page and navigate back they skip over the previous page (with the UI Action) go back one page farther. So I just want my UI Action to navigate to the URL instead of redirecting there. What method/syntax would I use?
Thanks,
Reed
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-30-2016 10:44 AM
You can apply it right to your action.setRedirectURL. If I were going to send my users to a specific form and want them to go to the home page when they are done, it might look like this:
var url = '/u_my_table.do?sys_id=' + some_sys_id_variable + '&sysparm_stack=home.do'
action.setRedirectURL(url);

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-30-2016 10:22 AM
Hi Reed,
You may be interested in the sysparm_stack parameter.
http://wiki.servicenow.com/index.php?title=Navigation_Stack#gsc.tab=0
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-30-2016 10:40 AM
Thanks Chuck, Yes, I am interested - and I looked at that before but I couldn't tell from the wiki article how I could apply it to my situation (I didn't want to go through 50 rounds of trial-and-error only to find out it doesn't do what I want).
Would I just include that parm in the URL in my setRedirectURL? Or would I have to do it in another statement prior to issuing my setRedirectURL?
Thanks,
Reed

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-30-2016 10:44 AM
You can apply it right to your action.setRedirectURL. If I were going to send my users to a specific form and want them to go to the home page when they are done, it might look like this:
var url = '/u_my_table.do?sys_id=' + some_sys_id_variable + '&sysparm_stack=home.do'
action.setRedirectURL(url);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-30-2016 12:47 PM
Thanks Chuck,
That does what I want. Your example was very helpful.