2011 Dec 05 6:57 AM
Hi All,
I have the requirement to put an excel file from presentation server to another remote system for this i am using the function modules
1) FTP_CONNECT to connect to the sourece as well as the destination systems --- Here i am able to hit the both systems.
2) for sending the data to the target system i am using FTP_COMMAND by passing the 'put' statement along with the soruce and destinations for the command parameter.
See the bellow code
CONCATENATE 'put'(t39) wa_file-pathname
INTO lv_cmd
SEPARATED BY space. " Forming the Command for data Transfer
CALL FUNCTION 'FTP_COMMAND'
EXPORTING
handle = lv_handle " Handle or Instance
command = lv_cmd " ASCII Command
compress = 'N' " No Compress
TABLES
data = gt_data
EXCEPTIONS
tcpip_error = 1
command_error = 2
data_error = 3
OTHERS = 4.
open C:\usr\desktop\upload.xlsx errno 22: Invalid argument
Please let me know how i can resolve this problem and how can I put this file in the destination system.
2011 Dec 05 8:39 AM
Check the function by trying with an excel file of format .xls.