Skip to Content
0
Former Member
Jul 16, 2009 at 04:19 AM

Some issues when consuming RFC2 model using WebDynpro Java CE 7.11

46 Views

Hi Experts ,

I'm using Web Dynpro for Java to develop our project. I have issues when I use RFC 2 model to call BAPI function . I already create the RFC 2 model successfully to call one PO BAPI function --- BAPI_PO_GETDETAIL. The whole project build and deploy successfully. At run time, it will call the execute() function of the model object. It also works fine and get the return values.

I just want to get two return objects : PO_Items and PO_Item_Schedules .

So far, every thing works fine. But when I want to iterate the PO_Items node and get each property value of current element, the following error occurs :

com.sap.tc.cm.base.exception.BaseModelRuntimeException: Class 'java.lang.String' of new attribute value is not assignment compatible for attribute 'Prnt_Price' of type 'boolean' in model class 'com.sap.demo.localwd.qaspomodel.Bapiekpo'

at com.sap.tc.cm.base.model.BaseGenericModelClass.setAttributeValue(BaseGenericModelClass.java:306)

at com.sap.tc.cm.arfc2.model.ARFC2GenericModelClass.unmarshalFromJCoRecord(ARFC2GenericModelClass.java:287)

at com.sap.tc.cm.arfc2.model.ARFC2ModelObjectCollection.doUnMarshalAt(ARFC2ModelObjectCollection.java:97)

at com.sap.tc.cm.arfc2.model.ARFC2ModelObjectCollection.get(ARFC2ModelObjectCollection.java:120)

at com.sap.tc.webdynpro.progmodel.context.ModelElementList.getElement(ElementList.java:1726)

... 72 more

I use the same way to iterate PO_Item_Schedules element. It also works fine. Therefore, I don't know why this error happens?