Scenario: An ALV list is generated depicting the last 10 sales orders created by the user. If the user wants to repeat the same order, the user would select one of the orders and process to create a sales order with data of the chosen sales order. This selection needs to be handled by a radio button on the ALV grid.
- Add a field for the radio button. This value will be a char4.
- For each row, populate the radio button variable in the internal table – use icon_radiobutton for selected record and icon_wd_radio_button_empty.
- While updating the field catalog ensure icon = ‘X’ and hotspot = ‘X’.
- Use user command to handle radio buttons.
A similar process is followed for the checkbox as well. Here checkbox = ‘X’ is used to indicate the value in checkbox.