Skip to Content
0
Former Member
Mar 26, 2009 at 02:06 PM

Try and End Try.

37 Views

Hello All,

Is there any disadvantage to use try and end try in the program.

I have developed a custom program. At starting of the program i have used TRY and at end of the program i have used catch and end try.

In order to avoid at any case short dumps in program.

Again inside the code at certain cases were the shot dump is expected i have used TRY and Catch, End try.

Please let me know is this good idea, to use try and End try in first and last of the program.

Thank you very much in advance.

Code :

Staring of the program TRY.

Select....

Perofm.....

Write ,....

Perofm.....

End of the program CATCH cx_root INTO l_oref.

l_text = l_oref->get_text( ).

MESSAGE l_text TYPE 'E'.

ENDTRY.

Thanks,

Feroz.