?
Solved

automatically send a file from my share directory to a ftp site.

Posted on 2007-03-28
7
Medium Priority
?
188 Views
Last Modified: 2010-04-13
My Operating System is Windows 2000.  I need to automatically send a file from my share directory to a ftp site.  I need to use MS Schedule Task to run this process daily @ 6am EST.  Please help as I am not familiar with .bat files/setup, etc.

Path contains folder to send = R:\\jax\dept\"PRogram1.csv"
FTP site = ftp:\\ftsmur1\VVG\jax\
My Login is anonymous


 
0
Comment
Question by:smcfarla
  • 4
  • 2
7 Comments
 
LVL 67

Expert Comment

by:sirbounty
ID: 18809363
Just schedule this command to run at 6am

ftp -s:c:\putfile.scr


PutFile.scr would contain the following
open ftsmur1
user
guest
guest
cd VVG\jax
put R:\\jax\dept\"PRogram1.csv"
quit


http://support.microsoft.com/kb/96269 gives greater detail
0
 
LVL 6

Expert Comment

by:kane77573
ID: 18810204
Yep follow Sir Bounty he has this one tied down
0
 

Author Comment

by:smcfarla
ID: 18812142
how do i schedule the command to run?  What application file do I need to open "PutFile.scr"?  Please help...
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 67

Expert Comment

by:sirbounty
ID: 18812460
1) Putfile.scr can really be 'anything'...I just used that as an example - the .scr denotes that it's a script, but it could just as easily be test.txt and still work, provided the ftp -s: points to that name

2) the schedule task can be done via the gui, or command line:

schtasks /create /ru system /sc daily /st 06:00:00 /tn FTPScript /tr "ftp -s:c:\putfile.scr"

should do it...
0
 

Author Comment

by:smcfarla
ID: 18812690
I understand how to create the .scr file {Thanks!!}
When I open a New Task (from Scheduled tasks), Where do I type my code?
Here are my options:
1. Run:
2. Start in:

I assume that I put the code in the "RUN:" option, is this right?
RUN:  schtasks /create /ru system /sc daily /st 06:00:00 /tn FTPScript /tr "ftp -s:c:\putfile.scr"

And  do I put the New Task.job location in the "Start in:" option?
Start in:  C:\\WNDOWS\Tasks\New Task.job

Sorry, this is a new experience for me.
0
 
LVL 67

Accepted Solution

by:
sirbounty earned 2000 total points
ID: 18813000
You can leave start in blank...it'll default to the path
You would place it in the run, but the command I gave you was to do it from the command line.
If doing it from the GUI (Scheduled tasks) - place this in the "Run" line:

c:\YourFile.bat
(where YourFile.bat is another file containing the line:

ftp -s:c:\putfile.scr

0
 
LVL 67

Expert Comment

by:sirbounty
ID: 18813032
Happy to help - thanx for the grade! :^)
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Compliance and data security require steps be taken to prevent unauthorized users from copying data.  Here's one method to prevent data theft via USB drives (and writable optical media).
Unable to change the program that handles the scan event from a network attached Canon/Brother printer/scanner. This means you'll always have to choose which program handles this action, e.g. ControlCenter4 (in the case of a Brother).
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question