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

check box

Former Member
0 Likes
593

hi all,

i am using table control which is referring to internal table and working area.

i have 1 field in the chain endchain under PAI is using check box.

may i know where should i do so that when show the data, record that already checked should appear grey out whereas those unchecked should allow user to do check in the check box?

for example, the second record status should grey out. actually material and quantity is read only column in table control. so basically the whole record should grey out if status has 'X'.

material quantity status

123 5000

321 2345 X

thanks

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
563

Hi,

In the LOOP..ENDLOOP of the PBO..You can disable the line..

Example

-


PROCESS BEFORE OUTPUT.

LOOP AT ITAB.

MODULE DISABLE_OUTPUT.

ENDLOOP.

MODULE DISABLE_OUTPUT.

IF ITAB-STATUS = 'X'.

LOOP AT SCREEN.

SCREEN-INPUT = '0'.

MODIFY SCREEN.

ENDLOOP.

ENDIF.

ENDLOOP.

Thanks,

Naren

5 REPLIES 5
Read only

Former Member
0 Likes
564

Hi,

In the LOOP..ENDLOOP of the PBO..You can disable the line..

Example

-


PROCESS BEFORE OUTPUT.

LOOP AT ITAB.

MODULE DISABLE_OUTPUT.

ENDLOOP.

MODULE DISABLE_OUTPUT.

IF ITAB-STATUS = 'X'.

LOOP AT SCREEN.

SCREEN-INPUT = '0'.

MODIFY SCREEN.

ENDLOOP.

ENDIF.

ENDLOOP.

Thanks,

Naren

Read only

gopi_narendra
Active Contributor
0 Likes
563

You will have to do this in the PBO of the screen.

write a module in the flow logic

module change_screen.

now in the module write as below

if itab-status = 'X'.

loop at screen.

if screen-name = 'screen field name for material' or

screen-name = 'screen field name for quantity' or

screen-name = 'screen field name for status'.

screen-input = 0.

modify screen.

endif.

endloop.

endif.

Regards

Gopi

Read only

0 Likes
563

hi,

screen cannot be used as i am modifying the table control.

i do not know what is the component, for example TC-? to disable the line if the status in the line has X.

thanks

Read only

0 Likes
563

Ok, in the PBO of the table control, use the same logic.

u can get the name of the TC from the layout. in the PBO u can use it like this

read table itab index <TC Name>-current_line.

if sy-subrc = 0.

if itab-status = 'X'.

loop at screen.

use the same logic here....

endloop.

endif.

endif.

Regards

Gopi

Read only

0 Likes
563

hi gopi and all,

thanks alot

gopi, your statement can work.

thanks again

i will reward accordingly.