03-12-2019 11:56 AM
Hello Abapers
I have a requirement in table control that the user can insert the row between two filled rows to make it a sub row of the first one. I have two buttons one is to insert row at the end and second is when a user select a line in table control and press the second button then the empty row should insert below that particular selected line.
your help will be appreciated.
03-12-2019 2:10 PM
Its simple, get the selected line, and insert empty row in internal table, declare one key field for both header and item rows so that is easy to insert row. Key field can be used to insert row if you are not able to insert empty row. Key field would be there in background, its our coding purpose, not required to display to user. Hope this solution works. You can also validate the user is trying to insert any other sub row(Second sub row) you can give error. Also you can sort the data with that key field declared in your internal table.
You can achieve with little bit coding.
Regards
Guru Prasad
03-14-2019 10:51 AM
Thanks Guru for your quick response
do you have the sample code of it? It would be great help to me.
03-14-2019 4:48 PM