Hi SAP experts,
i am learning enhancement technology now. Follow one guide from wiki, i implemented an enhancement in my custom program. but it cannot work. following is my code. i debuged, but the code among the enhancement cannot reiggered. they are all activated. Can anyone help me?
REPORT ZGET_FLIGHT_ENHANCEMENT NO STANDARD PAGE HEADING.
PARAMETERS:p_carrid TYPE sflight-carrid DEFAULT 'AA' OBLIGATORY.
DATA: it_flight TYPE TABLE OF sflight,
x_flight TYPE sflight.
START-OF-SELECTION.
ENHANCEMENT-POINT ZENH_POINT_FLIGHT SPOTS ZENH_SPOT_TEST.
$$-Start: ZENH_POINT_FLIGHT----
$$
ENHANCEMENT 1 ZENH_POINT_IMP_TEST. "active version
*Change the code by enhancement point.
IF p_carrid <> 'AA'.
MESSAGE 'Not air line AA' TYPE 'S'.
ENDIF.
ENDENHANCEMENT.
$$-End: ZENH_POINT_FLIGHT----
$$
ENHANCEMENT-SECTION ZENH_SECTION_GET_FLIGHT SPOTS ZTEST_SPOT2.
END-ENHANCEMENT-SECTION.
$$-Start: ZENH_SECTION_GET_FLIGHT----
$$
ENHANCEMENT 2 ZENH_POINT_IMP_TEST. "active version
IF p_carrid <> 'AA'.
MESSAGE 'Not air line AA' TYPE 'S'.
ENDIF.
ENDENHANCEMENT.
ENHANCEMENT 3 ZENH_SEC_IMP_TEST. "active version
WRITE:/ 'hello, this is from enhancement section'.
ENDENHANCEMENT.
ENHANCEMENT 4 ZTEST2. "active version
IF p_carrid <> 'AA'.
MESSAGE 'Not air line AA' TYPE 'S'.
ENDIF.
ENDENHANCEMENT.
$$-End: ZENH_SECTION_GET_FLIGHT----
$$
SELECT * FROM sflight
INTO TABLE it_flight
WHERE carrid = p_carrid.
IF sy-subrc = 0.
FORMAT COLOR = 1.
WRITE:/'Air line' , 15 'Flight number' , 30 'Fly date' , 43 'Price' .
FORMAT COLOR OFF.
LOOP AT it_flight INTO x_flight.
WRITE:/(8) x_flight-carrid CENTERED,
15(13) x_flight-connid CENTERED,
30(8) x_flight-fldate CENTERED,
40(13) x_flight-price CENTERED.
ENDLOOP.
ENDIF.