cancel
Showing results for 
Search instead for 
Did you mean: 

How to show few messages for each row in ALV

Former Member
0 Kudos

Hello,

I have an ALV with multi-select of rows. I also have few buttons which process all selected rows (bapi's and so on).

For each bapi that failed, I want to show to the user all error messages that the bapi return. The user should know the row in the ALV that each error message refer to.

I can't use the report_attribute_message method because the messages disappear if I scroll down the ALV or do other simple actions. In this way the user will miss the many messages.

Do you have an idea?

Thanks,

Ednri.

Accepted Solutions (0)

Answers (2)

Answers (2)

former_member184578
Active Contributor
0 Kudos

Hi,

I can't use the report_attribute_message method because the messages disappear if I scroll down 

The messages get cleared after a round-trip, so when you scroll down the messages are getting disappeared.

You can solve this issue as below:

while reporting error using report_attribute_error_message( ) pass the parameter IS_PERMANENT = abap_true.  So the message will not get disappeared after scroll down. Then later you can use clear_messages( ) of message manager to clear the messages.

hope this helps u,

Regards,

Kiran

Former Member
0 Kudos

Hi,

I've been tried to use the IS_PERMANENT parameter, but it's disabled some important functionality (I don't remember exactly what, but I think that the totals that I'm use in my ALV didn't worked well as example).

Thanks,

Ednri.

former_member184578
Active Contributor
0 Kudos

Hi,

I think that the totals that I'm use in my ALV didn't worked well as example).

I don't think so.! even if the totals aggregation is disabled, you could calculate the total manually by looping the internal table(work around). You have to use the IS_PERMANENT as the messages will get cleared during server roundtrip.

Regards,

Kiran 

Former Member
0 Kudos

If you can't use is_permanent you might have to represent your messages with every iview event

event...

Regards,

Edgar

Former Member
0 Kudos

Ednri,

What is your question and how do you present the bapi messages? If you present them in a log, like a separate ALV in a pop-up window with the error messages and original ALV line number this should not be an issue...

regards,

Edgar

Former Member
0 Kudos

Hi,

I prefer to show the messages in the same window of the original ALV and not in a different one.

If it's possible to show all the messages in the message area, while each message "connected" to the relevant row in the ALV by using the ATRIBUTE parameter, and the messages won't disappear after scroll down or other actions - that's what I'm looking for.

Thanks,

Ednri.