Skip to Content
author's profile photo Former Member
Former Member

How to call Instance Methods and set property values in BAPI?

In Project systems, for the three business objects viz.

Network, ProjectDefinition and WBS, there are two kinds of methods which are available : class methods and instance methods. We have tried calling some instance methods, for instance, BAPI_PROJECTDEF_GETDETAIL to get details pertaining to a project. While importing this BAPI, it shows two elements for mapping i.e. Current Internal Project(string) and Current External Project(string). We supplied these values for an existing project. Upon running this call through an XML client at our end, it

returned an error "Module Unknown Exception". This general message is present on every instance method thus far. Upon searching in BAPI Explorer for Project System->ProjectDefinition->GetDetail, we found that this BAPI didn't take any input parameter.

Following message was displayed in BAPI Exlorer for this BAPI:

"... Obligatory import parameters are the external and internal keys CURRENTEXTERNALPROJE and CURRENTINTERNALPROJE of the project definition.The system reads parameters contained in the structure


i) How to supply the values of Obligatory import parameters.

ii) What are the possible causes of this exception.

iii) How to call an instance method. We are using same mechanism for calling class as well as instance methods so far, we have been to call only class level methods successfully. Is there anything special that we

need to do to call instance methods.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Oct 04, 2005 at 07:24 AM


    what version is the SAP PS running? If WebAs or higher, create an inbound synch interface containing your two parameters in the request structure and as many as you require in your response structure. Generate an Inbound ABAP proxy, where you can plug in some code, i.e. create and instantiate an object of the required type and make the call to the BAPI.

    If SAP PS on lower than WebAs, then create a wrapper function module and make it RFC enabled. Then plug your code in here and do the same thing.

    Watch out for commits!



    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.