05-04-2009 1:52 PM
Hello,
I need copy a file from server to my local pc.
how can i do it?
thanks very much
05-04-2009 1:57 PM
Hi,
You can directly download the file from server to desktop using the transaction CG3Y.
Regards,
Santhosh.
05-04-2009 2:07 PM
Thank you Santhosh,
but i need do it in XI machine and don't exist the transaction CG3Y
other idea?
05-04-2009 4:48 PM
Hi, U can do this by the report.
DATA: BEGIN OF itab OCCURS 0,
text(1520) TYPE c,
END OF itab.
DATA: w_rec like line if itab.
File name on the server p_filenm.
OPEN DATASET p_filenm FOR INPUT IN TEXT MODE ENCODING DEFAULT.
IF sy-subrc = 0.
LOOP AT itab.
MOVE itab TO w_rec.
TRANSFER w_rec TO p_filenm LENGTH w_length.
ENDLOOP.
CLOSE DATASET p_filenm.
CONCATENATE 'C:' '\' p_filenm INTO fname1.
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
filename = fname1
TABLES
data_tab = itab
fieldnames = p_fieldnames
EXCEPTIONS
file_write_error = 1
no_batch = 2
gui_refuse_filetransfer = 3
invalid_type = 4
no_authority = 5
unknown_error = 6
header_not_allowed = 7
separator_not_allowed = 8
filesize_not_allowed = 9.
Hope this will help u
Thanks and Regards,
KC