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

selection screen

Former Member
0 Likes
824

How to get the fields of a selection screen in a single line?

9 REPLIES 9
Read only

Former Member
0 Likes
795

You have to use the syntax:

selection-screen begin of line.

parameter: A type mara-matnr.

parameter b type ekko-ebeln.

selection-screen end of line.

Check the sample program:

demo_sel_screen_beg_of_line_1

Regards,

Ravi

Read only

0 Likes
795

But, when we use this, we are not getting the field names in the selection screen that is A and B.So, how to get the field names?

Read only

0 Likes
795

You have to use comment statement:

SELECTION-SCREEN BEGIN OF LINE.

SELECTION-SCREEN COMMENT 1(10) text-001. "Dpuble click text-001 and create a label text

PARAMETERS: p1(3) TYPE c.

SELECTION-SCREEN COMMENT 14(10) text-002.. "Dpuble click text-001 and create a label text

p p2(5) TYPE c.

SELECTION-SCREEN END OF LINE.

Read only

0 Likes
795

When we use the "selection-screen comment" statement more than once, system is giving an error during activation.That is, in the example given by u,if we remove the statement "SELECTION-SCREEN COMMENT 14(10) text-002.", then only it's getting executed.Can u suggest why?

Read only

0 Likes
795

Hi

The problem is the length is overlapping , so what you can do is chnage the statement to some thing like this

SELECTION-SCREEN COMMENT <b>24</b>(10) text-002

if this also does not work , please try with a higher value,

Regards

Arun

Read only

Former Member
0 Likes
795

Hi ,

You can use the command

SELECTION-SCREEN BEGIN OF LINE.

you will also have to use SELECTION-SCREEN COMMENT

Regards

Arun

Message was edited by:

Arun R

Read only

sourabhshah
Product and Topic Expert
Product and Topic Expert
0 Likes
795

hi,

Several Elements in a Single Line

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.

Note that the selection text is not displayed when you use this option. To describe the elements, you must use the COMMENT addition of the SELECTION-SCREEN statement.

In the pos(len) formatting option of the SELECTION-SCREEN statement, you can omit pos between the statements specified above. The element is placed at the current position in the line. Between the statements specified above, you must not use a slash (/) in the pos(len) formatting option.

To determine the POSITION of an element in a line, you use:

SELECTION-SCREEN POSITION pos.

For pos you can specify a number, or one of the expressions pos_low or pos_high. pos_lowand pos_high identify the positions of the two input fields of a selection criterion. Use the POSITION addition only between BEGIN OF LINE and END OF LINE.

Examples

REPORT demo_sel_screen_beg_of_line_1 .

SELECTION-SCREEN BEGIN OF LINE.

SELECTION-SCREEN COMMENT 1(10) text-001.

PARAMETERS: p1(3) TYPE c, p2(5) TYPE c, p3(1) TYPE c.

SELECTION-SCREEN END OF LINE.

The following selection screen appears:

The line starts with the 'Title' contents of text symbol 001 and is followed by the input fields for parameters p1, p2and p3.

REPORT demo_sel_screen_beg_of_line_2 .

DATA wa_spfli TYPE spfli.

SELECT-OPTIONS airline FOR wa_spfli-carrid.

SELECTION-SCREEN BEGIN OF LINE.

SELECTION-SCREEN POSITION pos_high.

PARAMETERS field(5) TYPE c.

SELECTION-SCREEN END OF LINE.

The following selection screen appears:

The input field for the field parameter appears below the second field of selection criterion airline. For field, no selection text is displayed.

for more info about sel screen

http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/dba66935c111d1829f0000e829fbfe/frameset.htm

Regards,

Sourabh

Read only

Former Member
0 Likes
795

SELECTION-SCREEN BEGIN OF LINE.

SELECTION-SCREEN COMMENT 1(10) TEXT-001 FOR FIELD P1.

PARAMETERS: P1 LIKE SAPLANE-PLANETYPE, P2(5), P3(1).

SELECTION-SCREEN END OF LINE.

REGARDS

SHIBA DUTTA

Read only

Former Member
0 Likes
795

FOR THAT YOU HAVE TO USE

SELECTION-SCREEN COMMENT 1(10) TEXT-001 FOR FIELD P1.

JUST CHECK MY ANSWER

REGARDS

SHIBA DUTTA