- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-12-2022 10:59 PM
Hi ,
Could someone please help me with g_form.showFieldMsg?
As per script below, I have put some spaces in between however on the form, it shows with only 1 space in between words. How I can ensure that HH is directly below Hours box and mm is directly below minutes box and so on.
The script is
g_form.showFieldMsg('time_worked',' Time format is hh mm ss','info');
Solved! Go to Solution.
- Labels:
-
User Experience and Design
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-12-2022 11:45 PM
Hi,
html tags are not supported in field messages
try this once; it worked well for me
to give one space you can use this \u00a0; to give multiple spaces you can repeat that \u00a0
g_form.showFieldMsg('time_worked',' Time format is\u00a0hh\u00a0mm\u00a0ss','info');
Output: I tried with some other field on my form and it worked well
1) with 1 space
2) with 2 spaces
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-12-2022 11:08 PM
Hi
you can try this
g_form.showFieldMsg('time_worked',"Time format is");
g_form.showFieldMsg('time_worked', "hh");
g_form.showFieldMsg('time_worked', "mm");
g_form.showFieldMsg('time_worked', " ss");
Please Mark this as correct if its helpful.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-12-2022 11:19 PM
hi Mervin, unfortunately, the result is same. thanks for trying.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-12-2022 11:24 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-12-2022 11:41 PM