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

Icon in PushButton

kowong
Participant
0 Likes
1,179

Dear Expert,

I am using the following in the report:

SELECTION-SCREEN BEGIN OF LINE.

SELECTION-SCREEN PUSHBUTTON (24) text-003 USER-COMMAND S001.

SELECTION-SCREEN PUSHBUTTON (10) b_green USER-COMMAND S001.

SELECTION-SCREEN END OF LINE.

it shows the pushbutton. My question is,

How do we add an Icon into that button ?

Thank you ....

3 REPLIES 3
Read only

Former Member
0 Likes
586

Hi,

For that icon you have to call function module 'ICON_CREATE

Example:

TABLES sscrfields.

TYPE-POOLS icon.

SELECTION-SCREEN:

BEGIN OF SCREEN 500 AS WINDOW TITLE title,

PUSHBUTTON 2(10) but1 USER-COMMAND cli1,

PUSHBUTTON 12(30) but2 USER-COMMAND cli2

VISIBLE LENGTH 10,

END OF SCREEN 500.

AT SELECTION-SCREEN.

CASE sscrfields.

WHEN 'CLI1'.

...

WHEN 'CLI2'.

...

ENDCASE.

START-OF-SELECTION.

title = 'Push button'.

but1 = 'Button 1'.

CALL FUNCTION 'ICON_CREATE'

EXPORTING

name = icon_information

text = 'Button 2'

info = 'My Quickinfo'

IMPORTING

RESULT = but2

EXCEPTIONS

OTHERS = 0.

CALL SELECTION-SCREEN '0500' STARTING AT 10 10.

Please reward points if solved your issue.

Regards,

Renjith Michael.

Edited by: Renjith Michael on Jan 15, 2008 2:00 PM

Edited by: Renjith Michael on Jan 15, 2008 2:01 PM

Read only

Former Member
0 Likes
586

hi

good

i dont think it is possible in the normal report programming,yes it can be done in alv report.

thanks

mrutyun^

Read only

Former Member
0 Likes
586

Hi Kokwei,

I dont think adding an icon to the pushbutton ON the selection screen is possible. But if it is important, why dont you consider adding the buttons on the PF status application toolbar, that way you can have the icon as well as text.

Regards,

Aditya