Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Problems transfering generated XML file on server

Hi all.

I've got this problem: I generate XML using ixml library, and then I transfer it on local or on server. If I download it on local, there is no problem, but when I download that file on server, the file is corrupted - at the end of files are some rests of of other tags.

Basis: 4.6C

here is my code:

TYPES: BEGIN OF t_xml_line,
             data(256) TYPE x,
             END OF t_xml_line.


g_xml_table TYPE STANDARD TABLE OF t_xml_line.

* open file
  OPEN DATASET p_spath FOR OUTPUT IN BINARY MODE.
  IF sy-subrc NE 0.
    MESSAGE e299(r3) WITH 'Chyba pu0159i zalou017EenĂ­ souboru na serveru.'.
  ENDIF.

  LOOP AT g_xml_table ASSIGNING <fs_line>.
    TRANSFER <fs_line>-data TO p_spath.
    IF sy-subrc NE 0.
      EXIT.
    ENDIF.

  ENDLOOP.
  UNASSIGN <fs_line>.

  CLOSE DATASET  p_spath.

It's strange, because, when i send same table g_xml_table to GUI_DOWNLOAD, generated file is OK.

Some ideas?

Thx

Edited by: Filip Kouba on Sep 24, 2008 6:19 PM

Tags:
Not what you were looking for? View more on this topic or Ask a question