Interested in a ServiceNow event built for developers? Registration for now[dev]26 is officially open!

g_form.showFieldMsg() Disappears After Field Value Selection

PoojithaHasthi
Tera Contributor

We are using an onChange Client Script to display a g_form.showFieldMsg() message when certain conditions are met. The message is displayed correctly initially. However, once the user enters/selects a value in the field, the field message disappears automatically.

Our requirement is for the message to remain visible at all times as a dynamic hint whenever the condition is satisfied, even after the field value is selected or modified. Since a standard dynamic hint is not available for this use case, we are trying to use showFieldMsg().

Could you please advise:

  • Is this expected behavior of g_form.showFieldMsg()?
  • Is there a recommended approach to keep the message persistently visible while the condition remains true?
  • Are there any alternative solutions that can behave like a dynamic hint on the form?
5 REPLIES 5

@PoojithaHasthi 

then best approach

use Form annotation and show a text just above or below that field which guides user about the message

💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 10x ServiceNow MVP  ||  ✨ ServiceNow Community Leader