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: 

check box

Former Member
0 Kudos

hi gurus...

In selection screen I want to display the checkbox

in the right hand side of the text.(the default position of check box is left) . can i achieve this with out using screen painter.??

1 ACCEPTED SOLUTION

prasanth_kasturi
Active Contributor
0 Kudos

hi

use comment

check the example code, double click on the text-xxx and write your comments

SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.

SELECTION-SCREEN SKIP.

SELECTION-SCREEN BEGIN OF LINE.

PARAMETERS: r1 as CHECKBOX USER-COMMAND ucomm DEFAULT 'X'.

SELECTION-SCREEN COMMENT 3(17) text-002 FOR FIELD r1.

SELECTION-SCREEN POSITION 32.

PARAMETERS: r2 as CHECKBOX .

SELECTION-SCREEN COMMENT 34(17) text-003 FOR FIELD r2.

SELECTION-SCREEN END OF LINE.

SELECTION-SCREEN SKIP.

SELECTION-SCREEN END OF BLOCK b1.

regards

prasanth

10 REPLIES 10

prasanth_kasturi
Active Contributor
0 Kudos

hi

use comment

check the example code, double click on the text-xxx and write your comments

SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.

SELECTION-SCREEN SKIP.

SELECTION-SCREEN BEGIN OF LINE.

PARAMETERS: r1 as CHECKBOX USER-COMMAND ucomm DEFAULT 'X'.

SELECTION-SCREEN COMMENT 3(17) text-002 FOR FIELD r1.

SELECTION-SCREEN POSITION 32.

PARAMETERS: r2 as CHECKBOX .

SELECTION-SCREEN COMMENT 34(17) text-003 FOR FIELD r2.

SELECTION-SCREEN END OF LINE.

SELECTION-SCREEN SKIP.

SELECTION-SCREEN END OF BLOCK b1.

regards

prasanth

0 Kudos

what is the use of

SELECTION-SCREEN BEGIN OF LINE.

.........

........

.........

.........

SELECTION-SCREEN END OF LINE.

0 Kudos

Hi Diana,

SELECTION-SCREEN BEGIN OF LINE.

.........

........

.........

.........

SELECTION-SCREEN END OF LINE.

Use of the above statement is just to display it in the block .

&************ Reward Point if helpful*********************&

0 Kudos

Hi,

by default we get each line by line

to get the checkboxes in a single line we use

SELECTION-SCREEN BEGIN OF LINE.

.........

........

.........

.........

SELECTION-SCREEN END OF LINE.

not only checkboxes for fields,parameters,radibuttons we use it

to get the comment on the right side use the comment statement after the checkboxs statement

reward if helpful

prasanth

0 Kudos

PARAMETERS: r1 as CHECKBOX USER-COMMAND ucomm DEFAULT 'X'.

in this statement what is the use of USER-COMMAND

0 Kudos

Hi Diana,

User_command is used whenever you want to handle the check box click then you need to handle the user command.

0 Kudos

Hi,

The addition USER-COMMAND can be used to assign a function code fcode to the parameter. The function code fcode must be specified directly, and have a maximum length of 20 characters. To evaluate the function code, an interface work area of the structure SSCRFIELDS from the ABAP Dictionary must be declared using the statement TABLES. When the user selects check box on the selection screen, the runtime environment triggers the event AT SELECTION-SCREEN and transfers the function code fcode to the component ucomm of the interface work area sscrfields. If a function code used in the GUI status of the selection screen is specified for fcode, the selection screen processing is affected accordingly.

Rgds,

Bujji

former_member598013
Active Contributor
0 Kudos

Hi Diana

Use the below code to display the check box on the selection screen.


SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS : p_vornr AS CHECKBOX default 'X' .
SELECTION-SCREEN END OF LINE.

&*******Reward Point if helpful*****************&

Former Member
0 Kudos

hi,

SELECTION-SCREEN BEGIN OF LINE.

SELECTION-SCREEN COMMENT 3(17) TEXT-001.

parameters: p_ok as checkbox.

SELECTION-SCREEN END OF LINE.

regards,

madhu

Former Member
0 Kudos

hi,

yes you can achieve it .

To position a set of parameters or comments in a single line on the selection screen, you must declare the elements in a block enclosed by the following two statements:

SELECTION-SCREEN BEGIN OF LINE.

...

SELECTION-SCREEN END OF LINE

*******SELECTION SCREEN ********************

SELECTION-SCREEN : BEGIN OF BLOCK B WITH FRAME TITLE TEXT-001.

SELECTION-SCREEN: BEGIN OF LINE.

PARAMETERS: SNUM AS CHECKBOX USER-COMMAND RAD1.

SELECTION-SCREEN COMMENT 5(23) TEXT-001 FOR FIELD S_DOCNUM .

SELECT-OPTIONS S_DOCNUM FOR VBAK-VBELN MODIF ID SG1.

SELECTION-SCREEN: END OF LINE.

reward if useful.

thanks and regards

Edited by: hema bobbili on Jun 2, 2008 9:23 AM