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 to get the value of ESUH in ME51N ?

Former Member
0 Kudos
405

Dear Expert,

I am in need to check the value of Overall limit and Expected value in PR during the creation but in the user exists I donu2019t have access to ESUH-SUMLIMITa nd ESUH-COMMITMENT. Can anybody suggest how to get access to ESUH or get the above mentioned value in any user exit for ME51N. Looking forward for your expert advice.

Thanks

Sony

6 REPLIES 6

eduardo_hinojosa
Active Contributor
0 Kudos
143

Hi

Check if can trigger the enhancement SRVLIMIT.

Regards

Eduardo

Former Member
0 Kudos
143

Hi,

Try this,


DATA: IT_UESUH TYPE TABLE OF UESUH,
      WA_ESUH  TYPE UESUH.

FIELD-SYMBOLS : <FS1> TYPE ANY,
                <FS2> TYPE ANY TABLE.

* Validate only for below T-codes.
IF SY-TCODE = 'ME51N' OR SY-TCODE = 'ME52N' 
OR SY-TCODE = 'ME53N' OR SY-TCODE = 'ME54N'.

* Check if User has entered the Contract Limit.
  ASSIGN '(SAPLMLSL)XESUH[]' TO <FS1>.
  ASSIGN (<FS1>) TO <FS2>.
  IT_UESUH[] = <FS2>.

  IF IT_UESUH[] IS INITIAL.
    CLEAR: V_MESSAGE.
    V_MESSAGE = 'Reference to outline agreement is mandatory.'.
    MESSAGE E000(ZMM) WITH V_MESSAGE.
  ENDIF.
ENDIF.

Regards,

Danish.

0 Kudos
143

Could you please specify where I should write this code ? Actually I need to access this structure in ME51N transaction.

0 Kudos
143

Could you please specify where I should write this code ? Actually I need to access this structure in ME51N transaction

kesavadas_thekkillath
Active Contributor
0 Kudos
143

Have a look at EXIT_SAPLMLSL_001 - Check Limits in Service Specifications

0 Kudos
143

This user-exit does not get triggered in ME51N, ME52N, ME54N. Could your please advise how to use this