Skip to Content
0
Former Member
Oct 03, 2007 at 06:39 AM

How to use global classes and display returned data?

18 Views

Hello experts,

I have the following code in a program which accesses a global class (found in the class library). It executes one it's static methods. What I would like to do is to get hold of some elements of the returned data. How do I do that please?

Your help is greatly appreciated.

*********************************************************

***Use global class CL_ISU_CUSTOMER_CONTACT

DATA: o_ref TYPE REF TO CL_ISU_CUSTOMER_CONTACT.

DATA: dref_tab LIKE TABLE OF O_ref.

DATA: begin OF o_ref2,

CONTACTID TYPE CT_CONTACT,

P_INSTANCES TYPE string,

P_CONTEXT TYPE CT_BPCCONF,

P_CONTROL TYPE ISU_OBJECT_CONTROL_DATA,

P_DATA TYPE BCONTD, "<<<=== THIS IS A STRUCTURE CONTAINING OTHER DATA ELEMENTS

P_NOTICE TYPE EENOT_NOTICE_AUTO,

P_OBJECTS TYPE BAPIBCONTACT_OBJECT_TAB,

P_OBJECTS_WITH_ROLES TYPE BAPIBCONTACT_OBJROLE_TAB,

end of o_ref2.

TRY.

CALL METHOD CL_ISU_CUSTOMER_CONTACT=>SELECT "<<<=== STATIC METHODE & PUBLIC VISIBILITY

EXPORTING

X_CONTACTID = '000001114875' "Whatever value here

RECEIVING

Y_CONTACTLOG = o_ref

.

ENDTRY.

********************************************************************

  • WHAT I WOULD LIKE TO DO IS TO MOVE o_ref TO o_ref2 and then display:

  • 1) P_DATA-PARTNER

  • 2) P_DATA-ALTPARTNER

  • How can I do this please?