Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Catching Exception

Former Member
0 Likes
778

Hi,

How to catch the class expection in the Function module.

4 REPLIES 4
Read only

Former Member
0 Likes
609

hi,

regards,

Santosh

Read only

Former Member
0 Likes
609

You can do something like this :

try.

call method &1->add_aggregation

exporting

columnname = &3

aggregation = &4

receiving

value = &5.

catch <b>cx_salv_data_error</b> .

catch <b>cx_salv_not_found</b> .

catch <b>cx_salv_existing</b> .

endtry.

Declare the above exceptions in the <b>exception tab</b> of the FM.

Read only

0 Likes
609

Hi Ravi,

If the function module is remote function module then it will not work. But in my case the i am using the Remote Function module

Read only

Former Member
0 Likes
609

In case of RFC FM you can collect all the exceptions and populate an error file which can be stored on the application server immediately on execution of the FM.