Dynamic hyperlink variable
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-09-2024 06:57 AM
Hi Everyone,
Is it possible to display a dynamic hyperlink in a variable ? And is it possible in a MRVS ?
Only variable to display hyperlinks seems to be Rich Text Label, but not dynamically...
Thank you very much in advance for your support
Kr

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-09-2024 07:28 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-18-2024 03:57 AM
Hi @Community Alums
I was looking at similar requirement that i wanted to display the previously submitted RITM link on catalog form based on condition if variable on the catalog which is a reference field named XXX. If XXX submitted RITM is present then show recent RITM link on catalog form so the user can check their previous entries and submit new request on catalog.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-10-2024 12:53 AM
Hello Sandeep,
Thank you very much for your prompt reply.
So can we display dynamic hyperlinks with the Rich Text Label ?
Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-10-2024 01:23 AM
Yes, it is possible to display a dynamic hyperlink in a variable in ServiceNow. However, it's not directly possible in a Multi Row Variable Set (MRVS). Here are the steps to create a dynamic hyperlink in a variable: 1. Create a new variable of type "Macro" on your catalog item or record producer. 2. In the "Macro" field, you can use HTML and Jelly code to create a dynamic hyperlink. For example: html Link In this example, the hyperlink will be dynamically generated based on the short description of the current record. For MRVS, it's a bit more complex because MRVS doesn't support Macro variables. However, you can achieve a similar result by using a workaround: 1. Create a new variable of type "HTML" in your MRVS. 2. In the "HTML" field, you can use HTML and Jelly code to create a dynamic hyperlink. However, you need to use a GlideAjax call to get the data from the server. For example: html In this example, the getLink function in MyScriptInclude should return the URL for the hyperlink based on the sys_id of the current record. Please note that these are just examples and you need to adjust the code according to your requirements. Also, using HTML and Jelly code in variables is not recommended by ServiceNow because it can lead to security issues. Always make sure to properly escape any user input to prevent cross-site scripting (XSS) attacks.