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: 

Designing Selection Screen objects

Former Member
0 Kudos

Hello,

I have the requirement of having a checkbox (p_header) and parameter filepath (p_file) on the same line along with the text decription i.e. p_header and P_file.

It should be like this

__ p_header     P-file ________________

But I am only getting the checkbox and the p_file path...not the text decription as seen below:

My code is as below:

---------------------------------------------------------------------------------------------------------------------

SELECTION-SCREEN BEGIN OF BLOCK p2 WITH FRAME TITLE text-503.

SELECTION-SCREEN BEGIN OF LINE.

     PARAMETERS: p_header AS CHECKBOX.

     SELECTION-SCREEN COMMENT 4(17) text-a01 FOR FIELD p_header.

     SELECTION-SCREEN POSITION POS_LOW.

 

     PARAMETERS : p_file3 LIKE filename-fileintern OBLIGATORY

                              DEFAULT 'FILEPATH_xx.OUT'.

 

SELECTION-SCREEN END OF LINE.

SELECTION-SCREEN END OF BLOCK p2.

---------------------------------------------------------------------------------------------------------------------


I hope my requirement is clear enough.

I have included text-a01 in Goto->Text symbols and activated, but I am not getting the text on selection screen.

Would truly appreciate your help.

10 REPLIES 10

rahul_mb
Active Participant
0 Kudos

Hi Alita,

Try this code:

SELECTION-SCREEN BEGIN OF BLOCK p2 WITH FRAME TITLE text-503.

SELECTION-SCREEN BEGIN OF LINE.

      PARAMETERS: p_header AS CHECKBOX.

      SELECTION-SCREEN COMMENT 3(17) text-001 FOR FIELD p_header.

      SELECTION-SCREEN COMMENT 23(10) text-002 FOR FIELD p_file3.

      SELECTION-SCREEN POSITION 35.

      PARAMETERS : p_file3 LIKE filename-fileintern OBLIGATORY

                               DEFAULT 'FILEPATH_xx.OUT'.

SELECTION-SCREEN END OF LINE.

SELECTION-SCREEN END OF BLOCK p2.


And also maintain text elements:

text-001  --> Text Checkbox

text-002  --> Text File


Regards,

Rahul Muraleedharan.

Former Member
0 Kudos

Hello Rahul,

Thanks for your response, but not helpful.

Still the texts are not displayed, just the checkbox and the filepath block is, as shown in screenshot.


rahul_mb
Active Participant
0 Kudos

Hi Alita,

I can see the texts in the selection screen Please find the screenshot below:

Can you please check whether the text elements are created and it is activated?

Regards,

Rahul Muraleedharan.

Former Member
0 Kudos

Hello Rahul,

Yes I tried the same in another piece of code and it worked well. But didn't work in my original code. So I guess I had to maintain translations for the texts and now that I did it is working fine.

Thanks for your help.

Truly appreciated.

thanga_prakash
Active Contributor
0 Kudos

Hello Alita,

Check with the below code.


SELECTION-SCREEN BEGIN OF BLOCK p2 WITH FRAME TITLE text-004.

SELECTION-SCREEN BEGIN OF LINE.

     PARAMETERS: p_header AS CHECKBOX.

     SELECTION-SCREEN COMMENT 4(9) text-005.

     SELECTION-SCREEN COMMENT 20(7) text-006.

     PARAMETERS : p_file3 LIKE filename-fileintern OBLIGATORY

                              DEFAULT 'FILEPATH_xx.OUT'.

SELECTION-SCREEN END OF LINE.

SELECTION-SCREEN END OF BLOCK p2.

How to use the SELECTION SCREEN COMMENT.

SELECTION-SCREEN COMMENT <no. of position to skip from starting of line>(<length of the variable>) text-005.


Regards,

Thanga

Former Member
0 Kudos

Hi Menezes,

Try below code.

SELECTION-SCREEN BEGIN OF BLOCK p2 WITH FRAME TITLE text-503.
SELECTION-SCREEN BEGIN OF LINE.

PARAMETERS: p_header AS CHECKBOX.

SELECTION-SCREEN COMMENT 4(17) text-a01 FOR FIELD p_header.
SELECTION-SCREEN COMMENT 23(10) text-a02 FOR FIELD p_file3.


PARAMETERS : p_file3 LIKE filename-fileintern OBLIGATORY
                          DEFAULT 'FILEPATH_xx.OUT'.

SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK p2.



Text elements:


Text-A01    Check Box

Text-A02    File Path

Output:

Regards,

Manasa Veena P.

Former Member
0 Kudos

Hi Alita,

Use this code

SELECTION-SCREEN BEGIN OF LINE.

   PARAMETERS: p_file TYPE c as CHECKBOX.

   SELECTION-SCREEN COMMENT 5(5) s_txt01 FOR FIELD p_file.

   SELECTION-SCREEN COMMENT 15(5) s_txt02 FOR FIELD p_line.

   PARAMETERS: p_line TYPE string.

SELECTION-SCREEN END OF LINE.

INITIALIZATION.

s_txt01 = 'Check'.

s_txt02 = 'Line'.


0 Kudos

Hi Alita,

Please Check the below code.

SELECTION-SCREEN BEGIN OF BLOCK P2 WITH FRAME TITLE TEXT-503.

SELECTION-SCREEN BEGIN OF LINE.

PARAMETERS: P_HEADER AS CHECKBOX.

SELECTION-SCREEN COMMENT 4(17) TEXT-A01 FOR FIELD P_HEADER.

SELECTION-SCREEN COMMENT 30(10) TEXT-035 FOR FIELD P_FILE3.

PARAMETERS : P_FILE3 LIKE FILENAME-FILEINTERN OBLIGATORY DEFAULT 'FILEPATH_xx.OUT'.

SELECTION-SCREEN END OF LINE.

SELECTION-SCREEN END OF BLOCK P2.


I am getting the selection screen like below Screen shot.

I think you didn't pass the text elements. please check it once.


Regards,

Sri..

Former Member
0 Kudos

Hi Alita ,

Whatever you did is right, I thought you didnt activate the Text Eelements.

Please paste the below code, give Text Elements, Save and activate and Activate your Program in SE38,

Sure it Will works....

SELECTION-SCREEN BEGIN OF BLOCK p2 WITH FRAME TITLE text-503.

SELECTION-SCREEN BEGIN OF LINE.

      PARAMETERS: p_header AS CHECKBOX.

      SELECTION-SCREEN COMMENT 4(17) text-a01 FOR FIELD p_header.

       SELECTION-SCREEN COMMENT 23(10) text-a02 FOR FIELD p_file3.

       SELECTION-SCREEN POSITION 40.

      PARAMETERS : p_file3 LIKE filename-fileintern OBLIGATORY

                               DEFAULT 'FILEPATH_xx.OUT'.

SELECTION-SCREEN END OF LINE.

SELECTION-SCREEN END OF BLOCK p2.

Rgds,

Vijay SR

Former Member
0 Kudos

Thanks to all for your help.

Problem solved!