cancel
Showing results for 
Search instead for 
Did you mean: 

dealing with messages

Former Member
0 Kudos

hi ,

i am working on an application in which i have to deal with more than one exceptions and i am showing these on screen also as messages. Now code come across more than one exceptions it will run and finally ends up displaying all the messages on screen. Is it possible to limit the no of messages displayed in message area as one.Please suggest if it possible without much changes in code.

Thank You.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

You can limit the messages using the property 'MaxVisbileMessages' of the MESSAGE AREA UI element.

Please check the wdr_test_msg_area for the example.

Try to keep the Value as 1 for this MaxVisbileMessages for the UI element to show only one message at a time in the message area.

Regards

Lekha

Former Member
0 Kudos

Hi Vishavdeep,

In case if you are throwing exceptions by looping at exception table one way is instead of throwing standard exception messages throw one custom message of your custom message class describing the error.

In case if the exception you are getting in code sequentially one after other and for each you are thorwing the message using message manager class then you can simply write exit inside an if condition where you are displaying error messages. This will stop further excution and the other exceptions yet to come in the code will not be printed.

In case still you have some doubt please revert with some more explanation of your query.

Regards,

Neha