try this
# Edit your .netrc in your local homedirctory or create it with following
# parameters
# machine sapdata login xyz password xyz
# use chmod 600 .netrc for the right permissions
# FTP start
REMOTE_SERV="sapdata"
LOG_FILE="ftp_log.txt"
REMOTE_PATH="."
LOCAL_PATH="."
ftp $REMOTE_SERV <<-! 2>&1 | tee -i -a $LOG_FILE > /dev/null 2>&1
cd $REMOTE_PATH
lcd $LOCAL_PATH
dir
bye
!
# now you can edit the log file or
# load the log file by awk for further work in this script
# I donīt know how to get the recent files of the remote machine
# but you can work with the logfile and select your files by date and
# time for your own, by using awk.