Info message populated many times on the form from Business Rule

Saranya2
Tera Contributor

We have a before update BR on change table, whenever the record has been updated, it will populate info message on the form multiple times.

what could be the cause? any suggestion please.

 

ci br.PNG

1 ACCEPTED SOLUTION

jaheerhattiwale
Mega Sage
Mega Sage

@Saranya2 Add below line at top of business rule script that will remove old messages and new message will appear. in this way there is only one message.

 

gs.flushMessages()

 

Please mark as correct answer if this solves your issue.

Please mark the answer as correct or helpful based on impact
ServiceNow Community Rising Star, Class of 2023

View solution in original post

9 REPLIES 9

reshmapatil
Tera Guru

Hi @Saranya2 ,

 

Do you have any condition added to BR?

You can see messages multiple times maybe because your BR running multiple times if no conditions are added.

 

Regards,

Reshma

**Please mark my answer correct or helpful based on the impact**

jaheerhattiwale
Mega Sage
Mega Sage

@Saranya2 Add below line at top of business rule script that will remove old messages and new message will appear. in this way there is only one message.

 

gs.flushMessages()

 

Please mark as correct answer if this solves your issue.

Please mark the answer as correct or helpful based on impact
ServiceNow Community Rising Star, Class of 2023

Hi @jaheerhattiwale,

I have added the above line on the top of the business rule, It is populating info message only one time. That is fine. but In a single update how we were getting multiple messages on the form, what could be the root cause?

We have a condition in a BR as below.

ci br1.PNG

Community Alums
Not applicable

Hi @Saranya2 ,

 

Can you share your script?

 

Regards,

Gagan k