![]() |
![]() |
|
|
hi, i am writing script to transfer files from FTP server using inbuilt FTP utility commands.On FTP server files that i want to copy resides in a folder with the |
![]() |
|
|
#1 | ||
|
Guest
Posts: n/a
|
hi,
i am writing script to transfer files from FTP server using inbuilt FTP utility commands.On FTP server files that i want to copy resides in a folder with the name as 100308 it is 3rd October 2008(mmddyy) so can you tell me how to get the Date of FTP server and extract the month,date and year from the system date so that i will create a string by concatenating month,date and year and will copy the whole folder that will match with the string. I was not able to find the date command in FTP. i also need to extract the minutes and hours from the date using FTP command. Do we need to change to the shell of the FTP server and get the date. Also can i copy the whole folder using FTP commands??? if not what should i use to copy the whole folder??? |
||
|
|
|
#2 | ||
|
Guest
Posts: n/a
|
pandurang <pandurang@discussions.microsoft.com> wrote:
>i am writing script to transfer files from FTP server using inbuilt FTP >utility commands.On FTP server files that i want to copy resides in a folder >with the name as 100308 it is 3rd October 2008(mmddyy) so can you tell me how >to get the Date of FTP server and extract the month,date and year from the >system date so that i will create a string by concatenating month,date and >year and will copy the whole folder that will match with the string. I was >not able to find the date command in FTP. I think you'd have to run some process that would build your FTP command script dynamically. It could be C, C++, Perl, whatever you're comfortable with. (I'm not sure a shell script - *.bat or *.cmd file - can manipulate strings like that.) The process would construct the directory name, then use that to write the FTP command file, then invoke FTP. >i also need to extract the minutes and hours from the date using FTP command. >Do we need to change to the shell of the FTP server and get the date. I think your stuck there, as long as you're using FTP. I don't think you can "shell out" to the server. >Also can i copy the whole folder using FTP commands??? if not what should i >use to copy the whole folder??? Once you CD into the directory, you can use the MGET command to get all the files. -- Tim Slattery MS MVP(Shell/User) Slattery_T@bls.gov http://members.cox.net/slatteryt |
||
|
| Sponsored Links |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Documenting how screwed up Vista REALLY is with file transfering | TruthSquad@hope.com | Windows Vista | 3 | 08-30-2008 07:43 PM |
| Transfering Files from old CPU to new CPU | Kris | Windows XP | 3 | 07-03-2008 02:39 AM |
| transfering info | acetoolguy | Windows XP | 11 | 05-03-2008 02:06 AM |
| Multiple commands in batch file loop | mrgou | Windows Vista | 6 | 03-13-2008 05:55 PM |
| transfering files from 3 log-in into 1 log-in | besbabe | Windows XP | 2 | 11-06-2007 08:20 AM |