Hi all,
I have craeted the smartform and coverted the otf to PDF . Find below code.
For English PDF is comming propely , but arabic text is showing some junk .
when i execute smartform alone in arabic it comes propely but PDF is not comming correctly.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = gv_form
IMPORTING
fm_name = lv_fmname
EXCEPTIONS
no_form = 1
no_function_module = 2
OTHERS = 3.
IF sy-subrc EQ 0.
CLEAR: ls_control_parameters.
CALL FUNCTION 'SSF_GET_DEVICE_TYPE'
EXPORTING
i_language = '*' "'E'
i_application = 'SAPDEFAULT'
IMPORTING
e_devtype = lv_e_devtype.
ls_output_options-tdprinter = lv_e_devtype.
ls_control_parameters-no_dialog = abap_true.
ls_control_parameters-getotf = abap_true.
ls_control_parameters-LANGU = gv_langu.
CLEAR: gs_zhr_terhous, ls_job_output_info.
LOOP AT gt_zhr_terhous INTO gs_zhr_terhous.
CALL FUNCTION lv_fmname
EXPORTING
control_parameters = ls_control_parameters
output_options = ls_output_options
im_params = gs_zhr_terhous
IMPORTING
job_output_info = ls_job_output_info
EXCEPTIONS
formatting_error = 1
internal_error = 2
send_error = 3
user_canceled = 4
OTHERS = 5.
IF sy-subrc EQ 0.
IF ls_job_output_info-otfdata IS NOT INITIAL.
APPEND LINES OF ls_job_output_info-otfdata TO gt_otfdata.
ENDIF.
ENDIF.
ENDLOOP.
ENDIF.
*Display PDF
IF gt_otfdata[] IS NOT INITIAL.
CALL FUNCTION 'HR_IT_DISPLAY_WITH_PDF'
TABLES
otf_table = gt_otfdata.
ENDIF.
For English PDF is comming propely , but arabic text is showing some junk .
Thanks,
Deepa