Application Development 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: 

How do I get the PR number and item when I am in M06B0002 enhancement

Former Member
0 Kudos
404

We are using EXIT_SAPLEBND_001 for customized changes to the release strategy. All that is imported to this exit is ceban. How do I get the purchase requisition number (banfn) and line item number (bnfpo) from this include (ZXM06U13)?

7 REPLIES 7

ferry_lianto
Active Contributor
0 Kudos
103

Hi Karen,

Please try this in user exits EXIT_SAPLEBND_001.


DATA: WA_AREA(20) TYPE C,
      WA_EBAN     TYPE EBAN.
               
FIELD-SYMBOLS: <FS_EBAN>.
                                            
WA_AREA = '(SAPLEBND)E_EBAN'.

ASSIGN (WA_AREA) TO <FS_EBAN>.
WA_EBAN = <FS_EBAN>.

IF WA_EBAN-BANFN = <condition>.
  ...
ELSE.
  ...
ENDIF.

IF WA_EBAN-BNFPO= <condition>.
  ...
ELSE.
  ...
ENDIF.

Regards,

Ferry Lianto

0 Kudos
103

I would have thought this would work. I have coded a popup box to display the eban-banfn and nothing shows. so it is not working. I have tried this at the top of ZXM06U13 and at the top of the subroutine that this include calls.

Any other suggestion?

0 Kudos
103

Hi,

U can get the value of pr no like this:

DATA:W_BANFN TYPE EBAN-BANFN.

get parameter id 'BAN' FIELD W_BANFN.

U wil get pr no in field w_banfn.

Hope it solves ur query.

**Reward if useful**

Former Member
0 Kudos
103

Hi Karen,

check the following code

CALL CUSTOMER-FUNCTION '001'(EXIT_SAPLEBND_001)

EXPORTING

i_ceban = ceban

IMPORTING

e_ceban = ceban.

Here CEBAN structure have all the information about purchase req no.

Regards

Sreeni

0 Kudos
103

Yes ceban returns everything about the preq except for the requisiton number and item number.

ferry_lianto
Active Contributor
0 Kudos
103

Hi Karen,

Any standard transaction involved to execute this user exits?

Regards,

Ferry Lianto

0 Kudos
103

ME52N