ui action button that opens link in new tab when pressed
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2023 05:21 AM
Hello, i have a button that opens a link up in the current window. I want it to open up in a new tab instead, i have no clue how i go about doing this. Can i get any help?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2023 05:26 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2023 05:28 AM
this did not work.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2023 05:30 AM
@asd22 Try below code
g_navigation.openPopup(url);
Please mark as correct answer if this solves your issue.
ServiceNow Community Rising Star, Class of 2023
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-18-2023 05:30 AM
Hi,
use g_navigation.open() instead of action.setRedirectURL()
g_navigation.open("URL", "_blank"); //give the you link in place of URL it will opens in new tab
If it works Please mark my response as Correct / Helpful
Regards,
Kalyan