04-18-2012 7:20 PM
Hello,
I'm facing an issue with my enhancement point: I can't activate it although I didn't write a single line of code in it! It is just a post-exit method for method CONVERT_IF_TO_UI of class CL_HRTMC_AC_DEV_PLAN.
I first faced another issue, so maybe my activation issue is related to this.
Let me describe the entire process, including the initial issue and how I solved it, and I hope somebody will tell me what I'm doing wrong.
As you can see, I didn't write a single line of code and I get an error. Needless to say, if I write some code, I still get the error.
Thanks in advance for your help!
04-18-2012 8:58 PM
Hi Mateo,
interesting. You gave pretty much detail. Can you say where LCL_Z_REMOVE_ADD_QUALIF_DEV is defined as a class?
If it's a global class, then it should be activated.
If it's a local class, then make sure that it is visible here. I think, only global classes can be accessed in Post-Method enhancements because there is no enhancement available to add a local class to an existing class.
Regards
Clemens
04-19-2012 8:27 AM
Sorry, I did a mistake when I copied/pasted: there's no LCL_Z_REMOVE_ADD_QUALIF_DEV
I updated the original post with:
Row 30 contains code "CREATE OBJECT LCL_Z_MY_IMPLEMENTATION=>OBJ"
This class has been automatically created and its definition is located just before the post exit method:
CLASS LCL_Z_MY_IMPLEMENTATION DEFINITION DEFERRED.
CLASS CL_HRTMC_AC_DEV_PLAN DEFINITION LOCAL FRIENDS LCL_Z_MY_IMPLEMENTATION.
CLASS LCL_Z_MY_IMPLEMENTATION DEFINITION.
PUBLIC SECTION.
CLASS-DATA OBJ TYPE REF TO LCL_Z_MY_IMPLEMENTATION. "#EC NEEDED
DATA CORE_OBJECT TYPE REF TO CL_HRTMC_AC_DEV_PLAN . "#EC NEEDED
INTERFACES IPO_Z_MY_IMPLEMENTATION.
METHODS:
CONSTRUCTOR IMPORTING CORE_OBJECT
TYPE REF TO CL_HRTMC_AC_DEV_PLAN OPTIONAL.
ENDCLASS.
CLASS LCL_Z_MY_IMPLEMENTATION IMPLEMENTATION.
METHOD CONSTRUCTOR.
ME->CORE_OBJECT = CORE_OBJECT.
ENDMETHOD.
METHOD IPO_Z_MY_IMPLEMENTATION~CONVERT_IF_TO_UI.
*"------------------------------------------------------------------------*
*" Declaration of POST-method, do not insert any comments here please!
*"
*"methods CONVERT_IF_TO_UI
*" importing
*" !S_IF_DOCUMENT type HAP_S_DOCUMENT
*" changing
*" !S_UI_DOCUMENT type HRTMC_S_WD_DP_DOCUMENT
*" !S_UI_NAVIGATION type HAP_S_WD_PMP_NAVIGATION .
*"------------------------------------------------------------------------*
ENDMETHOD.
ENDCLASS.