Discussion Locked
0 helpful
1 reply
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.
I am trying to utilize a batch file to FTP info. This function has been completed sucessfully. However, I am having trouble getting functionality of error handling with this file. I assume that this is because of the FTP. Is there anyway to get error handling for this process since I want to automate it? I have tried to use the errorlevel it doesn't seem to produce the prper outcome. Any help would be greatly apreciated.
1 reply
by alan tan
Since transfer failure is not a fatal failure for FTP.exe (if you use it interactively, you still have change to correct the failure manually).
But in your situation, (non-interactively), you will have to redirect the output of the ftp to a log file with something like "ftp < input.fil > output.log" and then you need to use find.exe to exame the content of output.log.
You can then exame the errorlevel of the find command to see whether or not there is any errors during the transfer.
The find command returns 0 if string was found in the file, and returns >0 if not found.
Hope help.
This discussion is closed to new replies.
Trending Networks posts
Sort by Trending
Question Unanswered
How Can IT Teams Detect Hardware Bottlenecks in Business Networks?
0 helpful
0 replies
Question Locked
Using multi-NIC setup for NAS + router — better than VLAN?
0 helpful
4 replies
0 helpful
5 replies
Question Locked
Unknown device connected to my network
0 helpful
2 replies
Question Locked
How to change public IP without ISP?
0 helpful
2 replies