Application Development and Automation 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: 
Read only

FUNCTION 'REUSE_ALV_GRID_DISPLAY': KEYBOARD ENTER

Clemenss
Active Contributor
0 Likes
1,916

Hi ALV Experts,

in a user dialog, I call FUNCTION 'REUSE_ALV_GRID_DISPLAY' as a POPUP screen to show relevant data.

The User can leave the grid by closing the window (ALT-F4 or mouse-click on top-right-corner) or click the ENTER green hook in the menu bar below the grid.

Now they asked me why it does not react to hitting the ENTER key on the keyboard.

Actually, I know that SAP has problems with fully integrating some kind of standard, but I don't know if it is possible to make this ALV-popup sensible to detect the ENTER key.

Thank you to all readers,

also for all answers not related to the question

Regards,

Clemens

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,414

basically enter key word is not used for closing windows i guess

for the popup u might be having a close button

u might have written a n Fcode for that

check out the FCODE for enter and try this out

when 'CLOSE' or 'ENTE'.
  set screen 0.

6 REPLIES 6
Read only

Former Member
0 Likes
1,414

check the sample program.

<b>BALV_POPUP_TO_SELECT</b>

ENTER is nothing but selecting the record.

regards

prabhu

Message was edited by: Prabhu Peram

Read only

Former Member
0 Likes
1,415

basically enter key word is not used for closing windows i guess

for the popup u might be having a close button

u might have written a n Fcode for that

check out the FCODE for enter and try this out

when 'CLOSE' or 'ENTE'.
  set screen 0.

Read only

0 Likes
1,414

Thank you all,

it does not help. I do not use an own status and will not implement it.

OK, I implemented a call-back-functionality.

So, if the user doubleclicks on the information, the call-backk user_command is called and I set the parameter structure field selfield-exit = 'X'.

This way the grid is closed as well.

The thing is that the enter button of the status is set to application function &ONT. This function is not set as default. Hitting ENTER will not trigger anything at all.

Regards,

Clemens

P.S. How to award points to myself? <grin>

Read only

0 Likes
1,414

Hi

To make sensitive a GRID to ENTER key it should active the event CL_GUI_ALV_GRID=>MC_EVT_ENTER, but fm ALV GRID actives that event only if there's an input field: so it's not the case for popup.

U should create an your own popup using OO grid, in this way you can active that event.

Max

Read only

0 Likes
1,414

Thanks Max for the idea. The intention was to ask here because possibly a STANDARD software might provide a STANDARD solution.

Since SAP split up there development team into module-related profit centers, it gets worse from release to release.

Anyway: BALV_POPUP_TO_SELECT can be used, although it's no grid but an old-fashioned outdated list - just the right thing for the current customer.

Best regards,

Clemens

Read only

0 Likes
1,414

Hi

That's SAP!!!!

Max