2011 Jan 25 11:05 AM
Hi,
1. while customizing Purchase Order(me21n/me22n/me23n), I add three fields,
in that when i open me23n that fields are not disables.
i use this code,
case sy-tcode.
when 'me23n'.
loop at screen.
screen-input = 0.
modify screen.
endloop.
endcase.
bt it will not work.
any one can give the solutions for that?
2. that customized fields are comes under default tab customer data,
is it possible toi change the tab name?
give me the Solutions for that Issues.
Thanks.
Edited by: vino_abap on Jan 28, 2011 11:51 AM
2011 Jan 28 11:05 AM
Hi Vino,
Which exit/BADI you have used to add the fields? fields are at header level or at item level?
Assuming that you have used exit MM06E005 to add field at header level, the following are the answers:
1)You have to write the code in the PBO of screen 101. Create a PBO module in the screen using include ZXM06O01 and write the code in the following way :
IF SY-TCODE = 'ME23N''.
LOOP AT SCREEN.
IF SCREEN-NAME = 'WA_EKKO_CI-ZZREGIO'.
SCREEN-INPUT = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.2)You will not be able to change the tab name.
Thanks & Regards,
Faheem.
2011 Jan 28 11:05 AM
Hi Vino,
Which exit/BADI you have used to add the fields? fields are at header level or at item level?
Assuming that you have used exit MM06E005 to add field at header level, the following are the answers:
1)You have to write the code in the PBO of screen 101. Create a PBO module in the screen using include ZXM06O01 and write the code in the following way :
IF SY-TCODE = 'ME23N''.
LOOP AT SCREEN.
IF SCREEN-NAME = 'WA_EKKO_CI-ZZREGIO'.
SCREEN-INPUT = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.2)You will not be able to change the tab name.
Thanks & Regards,
Faheem.
2011 Jan 29 4:17 AM
Hi Faheem,
ya I given that code in PBO of screen 101 and that include ZXM06O01
bt my problem is not solve.
now i try to ur coding, that also not working.
wt a meaning for that ZZREGIO
if u give the solution it will help for me.
2011 Jan 29 4:34 AM
Hi Vinu,
WA_EKKO_CI-ZZREGIO is a screen field name which I have implemented here. Put your screen fieldname there.
This will work only when you have implemented exit MM06E005.
As Raymond said, it is always better to use transaction type, but unfortunately I_TRTYP is not available in that include. So declare a variable say W_TRTYP LIKE T160-TRTYP in ZXM06TOP and assign I_TRTYP to W_TRTYP in ZXM06U36 of function exit EXIT_SAPMM06E_006 as
W_TRTYP = I_TRTYP.Now your code should look like this :
IF W_TRTYP = 'A'. "A is a display mode
LOOP AT SCREEN.
IF SCREEN-NAME = 'WA_EKKO_CI-ZZREGIO'."Keep your screen fieldname here
SCREEN-INPUT = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.Thanks & Regards,
Faheem.
2011 Jan 29 4:52 AM
HI Faheem.,
thanks for the quick rly,
I tried that coding. bt my problem is not solved
actually i am using predefined project in cmod that is LO020
it is any problem for that.
Edited by: vino_abap on Jan 29, 2011 6:20 AM
Edited by: vino_abap on Jan 29, 2011 7:03 AM
2011 Jan 29 6:43 AM
Hi Vino,
Check which exit is assigned to that project? to check which exit is assigned goto Enhancement Assignments and check which exit is assigned to that project, if it is MM06E005, and you have followed what I have asked to do, then it should work for your requirement.Coz I worked a lot on exit MM06E005.
Thanks & Regards,
Faheem.
2011 Jan 29 7:08 AM
Hi Faheem ,
I already checked that. The exit name is MM06E005
I added the fields in header level only.
i tried that codes,
bt no change.
same screen only appear.
2011 Jan 29 7:09 AM
Hi Faheem ,
I already checked that. The exit name is MM06E005
I added the fields in header level only.
i tried that codes,
bt no change.
same screen only appear.
I dont know wr the mistake.
Edited by: vino_abap on Jan 29, 2011 8:09 AM
2011 Jan 29 7:19 AM
Hi Vino,
Hmmm, do the following :
1)Paste your code, with all the details like where you have written your code,include name etc.
2)Check whether that exit is active or not?
Thanks & Regards,
Faheem.
2011 Jan 31 7:16 AM
Hi Faheem,
Thanks u.
My problem solved.
Problem is,
Under PBO what ever i create include like zxm06o01
these are stored in include zxm06zzz
in my case that include is not activate.
that is the problem.
Now its fine.
Thanks,
2011 Jan 31 7:17 AM
Hi Faheem,
Thanks u.
I pasted my code in ur gmail. just check once.
My problem solved.
Problem is,
Under PBO what ever i create include like zxm06o01
these are stored in include zxm06zzz
in my case that include is not activate.
that is the problem.
Now its fine.
Thanks,
Edited by: vino_abap on Jan 31, 2011 8:18 AM
2011 Feb 03 11:42 AM
Hi frieds,
Thanks for the replay. these are very useful for me,
Now i have another issue.
what ever i add fields in me21n/22n/23n.(purchase order header level) same fields i want to add in sales order(header level).
for that i want to add that fields in vbak thro appand structure? if i want to add means,
further what to do,
for sales order what is the exit name for add a fields,
I found some exit name from that no exit name have a screen exit name,
so i cant get which is correct exit name for add a fields,
any one can give details about that,
Regards,
Vino,
2011 Feb 03 11:48 AM
Hi Vino,
To add fields in Sales Order at header level you have to use tab Additional Data B. To do that you have to add your fields in screen 8309 of program SAPMV45A. For details you can read SAP notes 302497 & 209278.
Thanks & Regards,
Faheem.
2012 Oct 22 5:33 PM
Hi, vinoth R.
My problem is solved.
Include zxm06zzz was inactive.
Only I have activated it and it work.
2016 Jul 15 9:38 AM
2011 Jan 28 12:21 PM
2011 Jan 29 4:26 AM
HI Raymond,
I try to use that i_trtyp also,
bt i got error..
field I_TRTYP IS UNKNOWN.
This is my code,
IF ( ( sy-tcode = 'ME21N' ) OR
( sy-tcode = 'ME21' ) OR
( sy-tcode = 'ME22N' ) OR
( sy-tcode = 'ME22' ) OR
( sy-tcode = 'ME23' ) OR
( sy-tcode = 'ME23N' ) ).
CLEAR i_trtyp.
IMPORT i_trtyp FROM MEMORY ID sy-uname.
LOOP AT SCREEN.
IF screen-name = 'EKKO_CI-custom field'.
IF i_trtyp = 'A'.
screen-input = '0'.
MODIFY SCREEN.
ENDIF.
ENDIF.
ENDLOOP.
ENDIF.
2011 Jan 28 12:26 PM
Hi,
Which user-exit are you using ??
Try Below:
case sy-tcode.
when 'ME23N'. "All Caps
loop at screen.
screen-input = 0.
modify screen.
endloop.
endcase.Regards,
Jovito
2016 Jun 14 1:24 PM
Following the step :
PROCESS BEFORE OUTPUT.
MODULE status_0101.
implement the MODULE status_0101 .
write the code :
MODULE status_0101 OUTPUT.
* SET PF-STATUS 'xxxxxxxx'.
* SET TITLEBAR 'xxx'.
IF SY-TCODE = 'ME23N'.
LOOP AT SCREEN.
IF SCREEN-NAME = 'EKKO_CI-ZZPOHDR_SPIN'. //field name
SCREEN-INPUT = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
ENDMODULE. " STATUS_0101 OUTPUT