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

Creating additional customised tabscreen under header data for me21n

Former Member
0 Likes
620

hi all.

i have a requirement for adding extra tabscreen (subscreen) undr headr data of me21n purchase requisitions .

and other thing is i want to know how we can raise an eror message if the user has filled all data in me21n except in customised tab screen that i am going to create.

waiting for great answwr.

bye.

sita ram,

6 REPLIES 6
Read only

mvoros
Active Contributor
0 Likes
601

Hi,

check this BADI ME_GUI_PO_CUST. Read documentation and view code sample in transaction SE18. You will have to implement BADI ME_PROCESS_PO_CUST as well.

Cheers

Read only

Former Member
0 Likes
601

Hi thanks for your answer,but actually iam new to badis and exits.

so could you please briefly explain me th step by step on how to create the tabscreen i m e21n and how to satisfy my requirement.

waiting for your response.

bye.

regards.

sita.

Read only

mvoros
Active Contributor
0 Likes
601

Hi,

you can find tons of general info BADIs on this forum. So basically go to transaction SE18 and enter name of your BADI - ME_GUI_PO_CUST. Please read carefully documentation. There is button for documentation. In documentation you can find following statement:

The Business Add-In (BADI) ME_GUI_PO_CUST enables you to integrate your own subscreens into the Enjoy purchase order at both eader and item levels.

So it looks like what you need. You have description for each method of BADI in documentation as well.Definitely you will have to implement method SUBSCRIBE. You will define your own screen in this method. Then you have to implement PBO and PAI logic (check methods TRANSPORT_TO_DYNP and TRANSPORT_FROM_DYNP). SAP provides examples for each BADI. You can read the example of BADIs implementation in Goto->Sample Code->Display. These examples are very well commented. I am pasting just example of SUBSCRIBE implementation


 DATA: ls_subscriber LIKE LINE OF re_subscribers.

* we want to add a customer subscreen on the item detail tab
  CHECK im_application = 'PO'.
  CHECK im_element     = 'ITEM'.

* each line in re_subscribers generates a subscreen. We add one subscreen in this example
  CLEAR re_subscribers[].
* the name is a unique identifier for the subscreen and defined in this class definition
  ls_subscriber-name = subscreen1.
* the dynpro number to use
  ls_subscriber-dynpro = '0001'.
* the program where the dynpro can be found
  ls_subscriber-program = 'SAPLMEPOBADIEX'.
* each subscreen needs his own DDIC-Structure
  ls_subscriber-struct_name = 'MEPO_BADI_STRUCT'.
* a label can be defined
  ls_subscriber-label = text-001.
* the position within the tabstrib can be defined
  ls_subscriber-position = 5.
* the height of the screen can be defined here. Currently we suport two screen sizes:
* value <= 7 a sevel line subscreen
* value > 7  a 16 line subscreen
  ls_subscriber-height = 7.

  APPEND ls_subscriber TO re_subscribers.

So basically you will define your new sub screen in this method. Do not forget that the BADI ME_PROCESS_PO_CUST is compulsatory for BADI ME_GUI_PO_CUST.

Cheers

Read only

Former Member
0 Likes
601

hi.

thanks for your quick answer but i want additional information about

how i can raise an error message when the user filled all the tabscreens in header data of me21n except in the tabscreen that i have created .

waiting for furhter response.

bye.

regards.

Sita ram,.

Read only

mvoros
Active Contributor
0 Likes
601

Hi,

you can use method check of BADI ME_PROCESS_PO_CUST for this purpose. As I wrote before, this BADI is mandatory for implementing the second BADI. Check documentation and Code sample in transaction SE18.

Cheers

Read only

Former Member
0 Likes
601

Hi Seeta,

You can use screen ecits

I'm also new to BADI's and screen exits, and I found this article very informative:

http://www.saptechnical.com/Tutorials/ExitsBADIs/ImplementScreenExit.htm

http://www.saptechnical.com/Tutorials/ABAP/ScrEXITCJ01/CJ01.htm

Hope this helps.

Rgds,

Joy