cancel
Showing results for 
Search instead for 
Did you mean: 

Highlight a particular row for error in a table

Former Member
0 Kudos

I have a table where data can change.

After user presses on SAVE, some validation on the data records is done.

Let's say i found that row no 3 has got an error.

Now I want to highlight this row and give an error. How to do that?

Thanks.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Get the element in error from the node.

in your case

lr_elem = node->get_element( index = 3 ).

Now pass exactly this element to message manager.

This row / attribute with appear red in error.

Cheers

Phil.


* get message manager
DATA: l_current_controller TYPE REF TO if_wd_controller,
      l_message_manager    TYPE REF TO if_wd_message_manager.

l_current_controller ?= wd_this->wd_get_api( ).

l_message_manager = l_current_controller->get_message_manager( ).

* report message
l_message_manager->report_attribute_error_message(
    message_text        =
    element             = lr_elem
    attribute_name      = "ATTRIBUTE IN ERROR GOES HERE" 

Answers (0)