‎2007 Jun 07 6:12 AM
Hi guys,
i want to disable some field in the Module pool selection screen... plz send the code and where i should i write in PBO r in PAI...
‎2007 Jun 07 6:15 AM
Hi,
You have to give the code in PBO..
Check this sample code.
process before output.
MODULE disable.
MODULE disable OUTPUT.
* Process the screen internal table.
LOOP AT SCREEN.
IF SCREEN-NAME = 'MARA-MATNR'. " Give the screen field name.
SCREEN-INPUT = 0. " Disable for input.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDMODULE.
Thanks,
Naren
‎2007 Jun 07 6:17 AM
hi ,
If you want ot disable some fields iun the Module pool program then use the LOOP AT SCREEN statement in your PBO part of the flow logic and disable the field .
In PBO of the flow logic of the screen !
Process before output.
Module disable_fields.
in your program :
module disable_fields.
loop at scren .
screen-name = ' <NAME OF THE SCREEN FIELD > ' , " here you specify the name of the screen field .
screen-output = '0' " this will disable the input option of the screen field .
Modify screen . " this will modify the screen with the above settings .
endloop.
endmodule.
Hope this helps !
Reward if helpful !
Regards,
Ranjita
‎2007 Jun 07 6:18 AM
hi,
write in PBO.
process before output.
MODULE Disable_field.
MODULE Disable_field.
IF p_up = 'X' .
LOOP AT SCREEN.
CASE screen-group1.
WHEN 'CCC'.
screen-input = 1. "Enable
screen-invisible = 0. "Disable
MODIFY SCREEN.
WHEN 'DDD'.
screen-input = 0.
screen-invisible = 1.
MODIFY SCREEN.
ENDCASE.
ENDLOOP.
ENDIF.
ENDMODULE.
‎2007 Jun 07 6:29 AM
hi,
We can do Screen modifications in Module pool program which is processed during the PBO Event.
process before output.
module modify_screen output.
module modify_screen.
<b>loop at screen.
if screen-name = <field name which is going to disable>.
screen-input =0. "disable for input
screen-output =0. "disable for output
endif.
modify screen.
endloop.</b>
the <b>screen</b> is the system genarated internal table it holds the attributes of each and every screen fields.
<u>Suppose if u r going to disable more than one fields, keep the fields in group.</u>
<b>loop at screen.
if screen-group1 = <group name under which we keep the fields>.
screen-input =0. "disable for input
screen-output =0. "disable for out put
endif.
modify screen.
endloop</b>
regards,
sudheer.
‎2007 Jun 07 6:51 AM
I WANT TO DISABLE 10 FIELDS IN THE SELECTION SCREEN, FOR THIS CAN TAKE
IF SCREEN-NAME = V_EBELN.
SCREEN-INPUT = 0.
ENDIF.
IF SCREEN-NAME = V_RFCDEST.
SCREEN-INPUT = 0.
ENDIF.
IF SCREEN-NAME = REQUESTER_ID.
SCREEN-INPUT = 0.
ENDIF.
IF SCREEN-NAME = V_ACC_CAT1.
SCREEN-INPUT = 0.
ENDIF.
IF SCREEN-NAME = DATE_FROM_TXT.
SCREEN-INPUT = 0.
ENDIF
or
should i take AND in if condition....plz send me the code....
thanks....
‎2007 Jun 07 9:46 AM
HI YOUR PROGRAM IS USEFUL TO DISABLE TEXT FIELDS .BUT NOW I NEED ENABLE THE SAME TEXT FIELDS AGAIN.
PLZ REPLY SOON
‎2007 Jun 07 10:12 AM
Thank u very much .your coding is very usefull and working good.
Now i have another doubt!
Can we change the screen background in screen painter.
plz do the needful.