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

provision for comments in selection screen

Former Member
0 Likes
831

hi,

iam balaji,can anyone help me with,how to create a field in which we can write our own comments,in the selection screen,the field should be like a notepad or editor type field,means not a single line field,the width of the field should be more...........????????????

6 REPLIES 6
Read only

Former Member
0 Likes
783

Have btn in the selection scrn . Upon clicking it , call the FM

'NOTICE_OPEN' which opens an editor.

Read only

Former Member
0 Likes
783

Hi Balaji,

If the program is a Module pool you can take Text Control.

And write your comments on that.

Read only

former_member189629
Active Contributor
0 Likes
783

Balaji,

First you need to design a screen say 100 using the Screen Painter.

Here, you need to create a Input/Output Box.

Note: With Release 6.10 you can set a representation for dropdown listboxes that also shows the key value in front of the description.

Listbox :

Visualization as listbox in which a list of entries is displayed with one short description each.

Refer to the following link:

http://help.sap.com/saphelp_nw2004s/helpdata/en/d1/801c2d454211d189710000e8322d00/frameset.htm

Once the Screen 0100 is ready, define the Selection-Screen using the Sub-Screen.

SELECTION-SCREEN BEGIN OF SCREEN <scrn> AS SUBSCREEN

[NO INTERVALS]

[NESTING LEVEL <n>].

...

SELECTION-SCREEN END OF SCREEN <scrn>.

Refer to the following link:

http://help.sap.com/saphelp_nw04/helpdata/en/e7/deb237b9a9a968e10000009b38f8cf/content.htm

Reward if helpful,

Karthik

Read only

Former Member
0 Likes
783

Hi,

u create a text box.

see this example.

DATA:container TYPE scrfname VALUE 'CONT',(cont is container in screen 101)

cl_container TYPE REF TO cl_gui_custom_container,

text_area TYPE REF TO cl_gui_textedit.

data:okcode type sy-ucomm.

set screen 101.

MODULE STATUS_0101 OUTPUT.

set PF-STATUS 'MENU'.

IF CL_CONTAINER IS NOT INITIAL.

CALL METHOD CL_CONTAINER->FREE

EXCEPTIONS

CNTL_SYSTEM_ERROR = 1

CNTL_ERROR = 2.

IF SY-SUBRC <> 0.

MESSAGE A000(ZTMW_MSGTAB).

ENDIF.

CLEAR CL_CONTAINER."clearing the custom container1

ENDIF.

IF CL_CONTAINER IS INITIAL.

CREATE OBJECT CL_CONTAINER

EXPORTING CONTAINER_NAME = CONTAINER.

CREATE OBJECT TEXT_AREA

EXPORTING

parent = CL_CONTAINER

wordwrap_mode = cl_gui_textedit=>WORDWRAP_AT_WINDOWBORDER

wordwrap_to_linebreak_mode = cl_gui_textedit=>true.

CALL METHOD CL_CONTAINER->link

EXPORTING

repid = sy-repid

dynnr = '0101'

container = CONTAINER.

CALL METHOD CL_CONTAINER->set_width

EXPORTING

width = 15.

CALL METHOD CL_CONTAINER->set_height

EXPORTING

height = 5.

ENDIF.

ENDMODULE. " STATUS_0101 OUTPUT

MODULE USER_COMMAND_0101 INPUT.

CASE OKCODE."okcode of screen 101

WHEN 'BACK'.

SET SCREEN 0.

ENDCASE.

ENDMODULE. " USER_COMMAND_0101 INPUT

<b>flow logic:</b>

PROCESS BEFORE OUTPUT.

MODULE STATUS_0101.

PROCESS AFTER INPUT.

MODULE USER_COMMAND_0101.

rgds,

bharat.

Read only

0 Likes
783

thx for the resply.........

Read only

0 Likes
783

hi bharath,

it is a report program,in the selection-screen i want a editor like window where i can write my comments and then show that finally in the layout, using smartforms.

plz find a sloution for this...............

regards,

balaji.s