The Message in showFieldMsg is disappearing immediately

uma17
Tera Guru
Hi All,
 
In the below code the message in showFieldMsg is disappearing immediately after appearing. If  we remove the g_form.clearValue() the message stays but the invalid value does not get cleared,
 
if (X > Y) {
        g_form.clearValue('abc'); 
        g_form.showFieldMsg('xyz', 'AAAAAAAAAAAAAAAA, 'error');
        return;
    }
 
Any idea why ?
 
Thanks,
Uma
15 REPLIES 15

Tried swapping the line , it did not work.

There is somehting that is either reloading/re saving the form or clearing the message. Cant be any thing else

-Anurag

AshishKM
Kilo Patron
Kilo Patron

Hi @uma17 

Tag( comment ) the return statement and check it again.

 

-Thanks


Please mark this response as correct and helpful if it helps you can mark more that one reply as accepted solution

Hi Ashish,

If  I comment the return the message itself is not displaying.

Thanks,

Uma

u accepted the solution means , the other issue catch by @Anurag Tripathi rresolved it.


Please mark this response as correct and helpful if it helps you can mark more that one reply as accepted solution