Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

ALV OO get selected row(s) / column(s) via ENTER Key (not mouse)

Former Member
0 Kudos

Not sure if this is possible but would like to get selected rows and / or columns when the ENTER key is pressed. I don't want to do it with a mouse click. I've already got a different event for DOUBLE CLICK.

By ROW and Column selection I select by marking the ROW / Columns and NOT by selecting data within the grid itself.

I have also have an event for ENTER when I'm editing a cell (data changed) etc so perhaps it can't be done this way.

Strange thing is if I go into debug mode I get taken to the PAI module where sy-ucomm is ENTER. If I just select the rows and press ENTER nothing happens.

The whole thing works fine on Mouse click but I was just wondering if you could do this by just pressing ENTER after selcting the rows / columns.

I think the problem might be that I've registered the ENTER event for EDIT functionality.

CALL METHOD grid1->register_edit_event

EXPORTING

i_event_id = cl_gui_alv_grid=>mc_evt_enter.

I think I'm trying to use the same event for 2 different actions so it might not be possible.

Is there any way round this --it's not a show stopper to get the user to do a mouse click but ENTER should be able to decide whether EDIT is required or whether a column / row selection is being done.

Cheers

Jimbo

1 REPLY 1

Former Member
0 Kudos

Hi anyone --all these gurus here --nobody got any answer on this one ??

Cheers

Jimbo