‎2009 Apr 28 2:14 PM
Hi .. Greetings to all,
Is it possible to edit the table controls in user exit...??
In exit ZXPADU03 for transaction PA40 , I have to change the table control's field property to display only mode for some users maintained in one table.
I had defined the control statement globally in ZXPADTOP :-
CONTROLS: tc_menu_event TYPE TABLEVIEW USING SCREEN 2000.
DATA: tc_menu_event1 like TABLE OF tc_menu_event .
DATA: cols LIKE LINE OF tc_menu_event-cols .
FIELD-SYMBOLS: <MENU_TC> TYPE CXTAB_CONTROL.
In exit ZXPADU03 I am trying with this code :-
IF SY-TCODE = 'PA40'.
SET SCREEN 2000.
ASSIGN TC_MENU_EVENT TO <MENU_TC>.
LOOP AT TC_MENU_EVENT1-COLS INTO COLS.
IF COLS-SCREEN-NAME = 'RP50G-WERKS'.
COLS-SCREEN-INPUT = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
But it is giving error during runtime on line ASSIGN TC_MENU_EVENT TO <MENU_TC>. that " This dynpro (2000) does not exist".
and I am unable to use "WITH CONTROL TC_MENU_EVENT" with loop as it is EXIT not in PBO or PAI module....
Please tell me how to solve this problem ....??
Regards,
Sourabh
‎2009 Apr 28 2:18 PM
Hi,
Get the values which you require from the importing parameters in the include into a global variable and then call the screen.
call screen 9000.
Double click 9000 and then create screen.Then you can work as if you are working in normal module pool.
Use ctrlshiftF5(display object list) for seeing the related includes in the exit.
‎2009 Apr 28 2:18 PM
Hi,
Get the values which you require from the importing parameters in the include into a global variable and then call the screen.
call screen 9000.
Double click 9000 and then create screen.Then you can work as if you are working in normal module pool.
Use ctrlshiftF5(display object list) for seeing the related includes in the exit.
‎2009 Apr 28 2:50 PM
Hi Jayanthi,
Thanks for the quick reply.
Actually I have no need to create new screen as my requirement is just to make a field of table in non editable mode which is present in standard screen (Table).
Only this code is enough if I am able to control the table screen elements in the exit...
IF COLS-SCREEN-NAME = 'RP50G-WERKS'.
COLS-SCREEN-INPUT = '0'.
MODIFY SCREEN.
ENDIF.
If i will create other screen ,, lots of other coding is required again... and even more than tat that table is used for HR actions like transfer , promotion, hiring etc.. so it is linked and configured with so many other things also ....
Is this is the only possible solution, can it be done in any other way.... ??
Thanks,
Sourabh
Edited by: Sourabh Jain on Apr 28, 2009 4:21 PM