Tuesday, November 23, 2010

Function Module to Read Feature value

*&---------------------------------------------------------------------*
*& Report YTEST_FEATURE
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*

REPORT YTEST_FEATURE.
data structure like pme04.
data feature like t549b-namen.
data back like t549a-abkrs.
data status(1).
BREAK-POINT.
structure-molga = '01'.
structure-persk = 'DN'.
feature = 'ABKRS'.

call function 'HR_FEATURE_BACKFIELD'
exporting
feature = feature
struc_content = structure
kind_of_error = space
importing
back = back
changing
status = status
exceptions
dummy = 1
error_operation = 2
no_backvalue = 3
feature_not_generated = 4
invalid_sign_in_funid = 5
field_in_report_tab_in_pe03 = 6
others = 7.
case sy-subrc.
when 2.
when 3.
when 4.
when 5.
when 6.
endcase.

No comments: