Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

how to exceed tooltip character limit

JamenW
Tera Expert

there is a 40 character limit set for a tooltip for a form or variable field.

how is this limit exceeded?

1 ACCEPTED SOLUTION

JamenW
Tera Expert

after looking into trying to update the element html with a client script, decided to try adjusting the dictionary on the tooltip field with a bumped up character limit like 200.

it worked like a charm!  🙂

View solution in original post

3 REPLIES 3

JamenW
Tera Expert

after looking into trying to update the element html with a client script, decided to try adjusting the dictionary on the tooltip field with a bumped up character limit like 200.

it worked like a charm!  🙂

Shubham_Jain
Mega Sage
Mega Sage

@JamenW there are ways to do 

 

1. Use a UI Policy with an Info Message

 

Instead of relying on the tooltip, you can display a longer message using a UI Policy with an Info Message:

Create a UI Policy on the form.

Set the condition based on when the tooltip should appear.

Add an Action to display a message (g_form.addInfoMessage('Your longer message here');).

 

2. Use a Client Script to Show a Longer Tooltip

 

You can override the tooltip using JavaScript in a Client Script:

 

g_form.getElement('your_field_name').title = "Your longer tooltip message here";

✔️ If this solves your issue, please mark it as Correct.


✔️ If you found it helpful, please mark it as Helpful.



Shubham Jain


tried the client script with no luck.
I see the html tooltip tag is "data-original-title" where the text is in the html output.

JamenW_0-1741956391282.png