02-26-2008 5:32 PM
Hi,
it is me again,
following situation
in a apab program i have a xmlfile as content of a string (not load from the filesystem - it is generated). Now i try to show the data in SAP Gui. Are there any possibilities?
Thanks in advance Stefan
03-04-2008 9:40 AM
data: l_xml type ref to cl_xml_document .
create object l_xml.
call method l_xml->parse_string
exporting
stream = xml_out. "xml_out is the variable which is holding the xml string
call method l_xml->display.
alternate option: you can use a custom control and show the xml using cl_gui_html_viewer class
02-26-2008 5:46 PM
Hi,
Please check for class CL_WD_RUNTIME_SERVICES
I try to display XSTRING as PDF document. may this will help you
CL_WD_RUNTIME_SERVICES=>ATTACH_FILE_TO_RESPONSE
a®
03-04-2008 9:40 AM
data: l_xml type ref to cl_xml_document .
create object l_xml.
call method l_xml->parse_string
exporting
stream = xml_out. "xml_out is the variable which is holding the xml string
call method l_xml->display.
alternate option: you can use a custom control and show the xml using cl_gui_html_viewer class
08-22-2013 3:04 PM
Hi,
first:I used call method lxml->display. and can see my xml file display in a small pop up window. How can I display the result without the pop up window ? (I only want to see one screen, no pop up window)
second:
how can i use the business document navigator? When I set the parameter 'WITH_BDN' to 'X' I see the navigator but my xml is nowhere to be seen. What I am doing wrong?
Thanks
11-08-2013 7:43 PM
Hi Maria,
To get that displayed on the same screen, you need to create a custom screen for that.
Step 1: Create the custom screen , say with number 100.
Step 2: Create a custom container within it and give a name say 'CONTAINER'.
Step 3: In its PBO create module and call the below static method
DATA lr_xml_ref TYPE REF TO cl_swf_wsp_xml_view.
cl_swf_wsp_xml_view=>create(
EXPORTING
i_container_name = 'CONTAINER'
i_repid = sy-repid " ABAP Program: Current Main Program
i_dynnr = '100' " ABAP Program: Number of Current Screen
i_xml_stream = lv_xml
IMPORTING
e_xml_view = lr_xml_ref " HTML Control for WSDL Display
).
sy-repid: As you know, this should be the program name from which the custom screen will be called .
I assume you already have the XML in xstring format and the same gets saved in variable lv_xml.
Once that create is called you will get the instance of the class
cl_swf_wsp_xml_view and then simple call the show method.
lr_xml_ref->show( ).
This should make the XML display within same screen and not as a Popup.
- Thanks , Somnath