cancel
Showing results for 
Search instead for 
Did you mean: 

Display error messages returned by the function module

Former Member
0 Kudos

Hi All,

I would like to display exception messages returned by function modules in message manager.

Now the error messages returned by function module are as displaying as a dump which are not user friendly

CALL FUNCTION '/MM/SET_DATA'

EXPORTING

pi_flag = lv_pi_flag

pi_delegateposition = lv_pi_delegateposition

IMPORTING

pe_sflag = lv_pe_sflag

EXCEPTIONS

no_rule_info = 1

update_failed = 2

insert_failed = 3

Please let me know how I would capture the error message returned from the FM and display it no the screen

Thanks for the help

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

you can check the sy-subrc after the FM.

if sy-subrc = 1.

lv_txt = 'no_rule_info'.

endif.

and then pass the lv_txt to method REPORT_ATTRIBUTE_ERROR_MESSAGE

Answers (0)