Hello Everyone,
I have a very simple sapscript form (it's an old form but does what we need it to do) that is currently being displayed in an Abap Web Dynpro. This display in the WDA is correct in everyway.
We have recently installed a new landscape and I am wanting to use the same (a copy) WDA in the new system. In the new system, the WDA does not show the PDF correctly. In the PDF output, there is an '#' character between each relevent character. For example, one line is as follows:
#P#u#r#p#o#s#e#/#S#c#o#p#e#
In debugging both WDA's side by side, the only difference I noticed was that table lengths in the new system seemed to have doubled. For example, I have a table of type tsfotf. The length in the old R/3 system is 72; however, it is 144 in the new system. I can only see this in debug mode. The tables are exactly the same in SE11.
Does anyone have any idea what would be causing the '#' between each field?
Best Regards,
Scott
PS - I have pasted my code below for reference.
DATA l_current_controller TYPE REF TO if_wd_controller.
DATA i_otf TYPE tsfotf.
l_current_controller ?= wd_this->wd_get_api( ).
CALL FUNCTION 'CONVERT_OTF'
EXPORTING
format = 'PDF'
IMPORTING
bin_filesize = pdf_size
bin_file = pdf_data
TABLES
otf = otf[]
lines = l_dummy
EXCEPTIONS
err_max_linewidth = 1
err_format = 2
err_conv_not_possible = 3
OTHERS = 4.
DATA: node_pdf TYPE REF TO if_wd_context_node,
elem_pdf TYPE REF TO if_wd_context_element.
CALL METHOD wd_context->get_child_node
EXPORTING
index = USE_LEAD_SELECTION
name = 'PDF'
RECEIVING
child_node = node_pdf.
get element via lead selection
elem_pdf = node_pdf->get_element( ).
set single attribute
elem_pdf->set_attribute(
EXPORTING
name = `SOURCE`
value = pdf_data ).