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

BAPI_PR_CREATE

Former Member
0 Likes
1,674

Hello Gurus,

I am trying to use the BAPI_PR_CREATE but I have an error, I have filled the PRACCOUNT and the PRACCOUNTX , I have filled the PREQ_ITEM field for both. I have filled the KOSTL value.

Some help me please.

thanks you.

1 ACCEPTED SOLUTION
Read only

Jelena_Perfiljeva
Active Contributor
0 Likes
1,567

Have you tried to run 'where used' for the message and then debug it checking when exactly the error occurs?

8 REPLIES 8
Read only

Jelena_Perfiljeva
Active Contributor
0 Likes
1,568

Have you tried to run 'where used' for the message and then debug it checking when exactly the error occurs?

Read only

0 Likes
1,567

Hello Jelena,

Yes, several times I have tried to debug the BAPI but really it's so confuse, I dont understand what the BAPI is doing. I dont know where is the error, the message error is a global class I dont know how to solve my problema.

Read only

0 Likes
1,567

Have you tried to put a break-point at MESSAGE statement and check if the debug stops at message ME 083 ?

Read only

0 Likes
1,567

yes, more than that, I have identify the class where the error messages are stored, this is the class called CL_MESSAGE_HANDLER_MM, this is located inside INCLUDE L2105I01,

I have identified how the message is stored

CL_MESSAGE_HANDLER_MM->ADD

CL_MESSAGE_MM=================CP CREATE

SAPLMEREQ  LMEREQF27 HAS_TEXT_DIFFERENT_LANGUAGE  (line 713)

SAPLMEREQ  LMEREQF04 COPY_FROM_MATERIAL_MASTER (line 691)

SAPLMEREQ  LMEREQF04 IS_VALID (line 925)

SAPLMEREQ  LMEREQF03 LIF_RULE_MM~EXECUTE (line 416)

SAPLMEREQ  LMEREQF03 CHECK_PRE_CONDITIONS (line 685)

I have tried to identified before this storing message how the error is generated but I can't

It's so confuse to debug this BAPI.

Read only

0 Likes
1,567

Did you try to create a PR in ME51N using the same values that you passing to the BAPI?

Read only

0 Likes
1,567

Yes; i have created a PR using  ME51N, but in the dynpro are less fields that BAPI requires, for example the header BAPI requires more fields than the PR using ME51N , the same way each position ítem , so perhaps when programming I am missing a value that i dont know, the error says CENTRO COSTO, but I have already put the centro costo.

I have created the PR using ME51N, I give the same values to the BAPI but this one sends an error message.

What would be the error?

I dont know, I already have 3 days trying to discover the error, really it is so hard to solve this error. I dont know how actually.

Read only

0 Likes
1,567

Check the thread below, hope it helps:

Regards,

Felipe

Read only

0 Likes
1,567

Thank you Felipe, the solution is the thread http://scn.sap.com/thread/1583820

Excellent!!!