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

SAP ABAP - Module Programming

Former Member
0 Likes
1,092

In selection screen, I have around 180 input boxes. My Requirement is if my cursor is on 1st input box and I press 'ENTER', then cursor should go to next input box. can anyone please help, how to achieve this functionality?

1 ACCEPTED SOLUTION
Read only

former_member1716
Active Contributor
943

Hello SANDARBH SINGH,

You Just need to use the concepts of GET CURSOR in PAI event along with SET CURSOR in PBO event.

Sample Code Below for reference

*****PAI EVENT
GET CURSOR FIELD local_Cursor_Variable

*****PBO EVENT
CASE local_Cursor_Variable.
WHEN 'FIRST FIELD'
SET CURSOR FIELD 'FIELD2'
WHEN "SECOND FIELD'
SET CURSOR FIELD 'FIELD3'
Until The Last field

Note:If you wanted to ensure the user to enter all the fields use OBLIGATORY Keyword    for all fields

Regards!

4 REPLIES 4
Read only

FredericGirod
Active Contributor
0 Likes
943

just set parameter as obligatory, by default it will work like that

otherwise

AT SELECTION-SCREEN ...

SET CURSOR ...

Read only

former_member1716
Active Contributor
944

Hello SANDARBH SINGH,

You Just need to use the concepts of GET CURSOR in PAI event along with SET CURSOR in PBO event.

Sample Code Below for reference

*****PAI EVENT
GET CURSOR FIELD local_Cursor_Variable

*****PBO EVENT
CASE local_Cursor_Variable.
WHEN 'FIRST FIELD'
SET CURSOR FIELD 'FIELD2'
WHEN "SECOND FIELD'
SET CURSOR FIELD 'FIELD3'
Until The Last field

Note:If you wanted to ensure the user to enter all the fields use OBLIGATORY Keyword    for all fields

Regards!

Read only

Former Member
0 Likes
943

Thanks Satish Kumar Balasubramanian, after using this its working fine now.

Read only

jerryjanda
Community Manager
Community Manager
943

If you've received the correct answer, could you please accept Satish's answer and close out the question? This will help people who have the same question in future, plus it ensures that Satish gets recognition for assisting you. Thanks!

Make sure to subscribe to What's New!