Code for raising an exception
I need to handle an exception.
There is a functionality to upload file from presentation server to Webdynpro. It allows me to only upload .csv file or text file. When I try to upload .xls file it gives the following err
The following error text was processed in the system MI2 : Error occurred during character conversion
The error occurred on the application server fmsap275_MI2_02 and in the work process 0 .
The termination type was: ERROR_MESSAGE_STATE
Hoe can i handle this using raise exception? I have never coded for TRY, CATCH etc before
hi SIM ,
check out this sample code
* get single attribute wd_context->get_attribute( EXPORTING name = `DATASOURCE` IMPORTING value = l_xstring ). CALL FUNCTION 'HR_KR_XSTRING_TO_STRING' EXPORTING in_xstring = l_xstring IMPORTING out_string = l_string. SPLIT l_string AT cl_abap_char_utilities=>newline INTO TABLE i_data.