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: 

Activate Version Management for BAPI Purchasing Contract

SilasL
Explorer
0 Kudos
656

Hey,

I am trying to create purchasing contracts by using BAPI_CONTRACT_CREATE in a program. Since version management is not support at the moment, the purchasing contracts do not have version management at creation.

I understand that SAP has stated that the workaround is using ME32K or ME32L, however my team wants the version management to be activated automatically at creation, not manually after the program ran.

Is there another workaround where we can make the program automatically activate version management before the program terminates, and if so, how would I implement that into my program?

Also, I see that in this SAP Note 1046794 - FAQ: BAPI for Outline Agreement - SAP ONE Support Launchpad, the answer to question 11 says that version management is a missing functionality.

Does that mean SAP will eventually add the functionality back into BAPI, and if they are, do we know the status on that?

4 REPLIES 4

Sandra_Rossi
Active Contributor
0 Kudos
290

The notes are updated from time to time: if SAP develops a new feature, they will update the relevant notes.

So, the note is still valid (Version 19 from 03.11.2020, both in English and German).

i.e. you need to update manually via ME32K or ME32L (or automatically by creating a program based on SAP GUI Scripting).

0 Kudos
290

Hey Sandra,

Thanks for your quick response. After testing your suggestion, I don't believe this satisfies my requirement.

If I were to use SAP GUI Scripting, I would open the contract by ME32K and save the contract. However, since there aren't any relevant changes to the contract, it wouldn't create a new version.

Did you have a different implementation of the script?

Thanks,

Silas

0 Kudos
290

I don't get your point. You want to create a contract with version management, BAPI don't support version management, only transaction codes do. The SAP note is talking about ME32K/ME32L but of course for creation it's ME31K/ME31L. So, by creating the contract with ME31K/ME31L (using SAP GUI Scripting), you will have version management.

0 Kudos
290

Hey Sandra,

Let me try to clarify the situation.

I have a program that creates contracts by BAPI_CONTRACT_CREATE. At the end of the program, a screen appears with a table that has objects with their contract numbers. The user is allowed to click on these contract numbers to view that contract. Currently version management is not support, so the contracts do not have version.

However, my team wants the contract to have versions management at this point when the user is viewing the contract and not after. Right now, the workaround is to use ME32K but that would be ran after the program terminates and that's not what my team wants.

Is there another workaround to getting version management activated by the time the user views the contracts or is it currently not possible?

Thanks,

Silas