FTP a file:Get return code if ftp is unsucessful.
Posted: 23 Jan 2015 11:16
Hi All,
I am trying to ftp a file using standard ftp command as - ftp -s:test.ftp. The "test.ftp" consist of below commands:
open 11.11.11.11
user
password
put file1
quit
The file is ftp'd successfully but the logs does not show me any return code as 0 or success message. I want some return code to be displayed so that if ftp is not successful due to any reason like - Connection failed, login incorrect or Traget not available then i can display message as "FTP was not successful". Can someone please help?
I am trying to ftp a file using standard ftp command as - ftp -s:test.ftp. The "test.ftp" consist of below commands:
open 11.11.11.11
user
password
put file1
quit
The file is ftp'd successfully but the logs does not show me any return code as 0 or success message. I want some return code to be displayed so that if ftp is not successful due to any reason like - Connection failed, login incorrect or Traget not available then i can display message as "FTP was not successful". Can someone please help?