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: 

How to set Traffic lights in module pool

Former Member
0 Kudos
2,183

How to set Traffic lights in Module pool programing.

If all the items are processed then i need to set Green signal,

if partial then Yello

if nothing then red.

1 ACCEPTED SOLUTION

Former Member
0 Kudos
987

just use the function module create_icon........importing the icon_name into a status_icon.....declare a field with name as status icon. do this in pbo....

9 REPLIES 9

RichHeilman
Developer Advocate
Developer Advocate
0 Kudos
987

It depend on what your UI looks like. Do you have a table control which is in your screen? And you want to set a light for each row of the table control? If so, all you need to do is set the column in the table control as a status field, then in your program you can write the icon to the internal table field.

type-pools: icon.
* This example simply writes the icon to the status field for all records.
  loop at itab.
     write icon_green_light as icon to itab-status.
     modify itab.
   endloop.

Regads,

Rich Heilman

Former Member
0 Kudos
988

just use the function module create_icon........importing the icon_name into a status_icon.....declare a field with name as status icon. do this in pbo....

Former Member
0 Kudos
987

I am not using Table control.

I am just having a screen with 4 fields which will have Contract number

If i give the contract number value, and save, it has to do some process and has to display the lighjt option

0 Kudos
987

Oh ok, then it is even easier, you can simply put a status field in your dynpro, and after doing the processing, simply write the icon to the field as before.

write icon_Green_light as icon to some_field.

Here SOME_FIELD is the field defined on the dynpro.

Regards,

Rich Heilman

0 Kudos
987

See the MD04 or MD06 Transaction for better idea

Former Member
0 Kudos
987

hI,

I didnt get any FM like create_icon.

0 Kudos
987

check this program <b>demo_dynpro_status_icons.</b>

Former Member
0 Kudos
987

Hi Sumi,

You can find values corresponding to ICONs in the type group ICON.

CONSTANTS: c_err(4) TYPE c VALUE '@0A@'.

CONCATENATE

c_inf

text-082

into v_field separated by space.

pass the v_field to the screen, this will display the icon and the text following it.

Regards,

George

RAkumawat
Discoverer
0 Kudos
918

Just make sure that field not in editable field