sdlangers Posted October 3, 2005 Posted October 3, 2005 hi, my dedicated server has a backup server which i can copy files to using these steps: i have to open up IE and type in this url: ftp://myuser@mybackupserver.com/ it then prompts me for the password which i enter, then i can simply drag the files into that window and it copies them over however, i would like to write a .net program to copy some files over automatically and then schedule it to run nightly can someone point me in the right direction for trying to code the above procedure. how do you specify the ftp site as the destination, how do you specify the user/pass etc. thanks! Quote
Nate Bross Posted October 4, 2005 Posted October 4, 2005 I don't suppose the servers are on the same LAN and you could map a network drive. And you just use FTP for convenience? If so, you could write a batch file and schedule a task. Like this @echo off copy "C:\MyFile.ext" "D:\ACopyofMyFile.ext" copy "C:\My2ndFile.ext" "D:\ACopyofMy2ndFile.ext" Otherwise check out the links ilya2 posted at the end of this thread http://www.xtremedotnettalk.com/showthread.php?t=92744 you should be able to pick up some 411 there. Quote ~Nate� ___________________________________________ Please use the [vb]/[cs] tags on posted code. Please post solutions you find somewhere else. Follow me on Twitter here.
sdlangers Posted October 4, 2005 Author Posted October 4, 2005 I don't suppose the servers are on the same LAN and you could map a network drive. And you just use FTP for convenience? If so, you could write a batch file and schedule a task. Like this @echo off copy "C:\MyFile.ext" "D:\ACopyofMyFile.ext" copy "C:\My2ndFile.ext" "D:\ACopyofMy2ndFile.ext" Otherwise check out the links ilya2 posted at the end of this thread http://www.xtremedotnettalk.com/showthread.php?t=92744 you should be able to pick up some 411 there. Hi, thanks for the reply.. i wish it was that simple :) the ftp drive cannot be mapped as a network drive, so i cant just use a drive letter. i also tried that link you sent - the FTPClient in C# is a great program, but i cant get it to work for me.. problem is they use this line of code to connect: aCN.Open("192.168.4.67", "anonymous", "", FTPMode.Active); but i have to use the following syntax via a web-browser to connect: "ftp://username@backupserver.com" then it prompts me for the password, which i type in, and then i can connect this is the ONLY way i can connect - i cannot even connect from regular FTP software. it HAS to be from within the browser on my dedicated server.. i cant even connect this way from any other computer. anybody got any ideas on how to code this? Quote
sdlangers Posted October 4, 2005 Author Posted October 4, 2005 oh.. nevermind - i got that FTPClient C# dll working i just needed to use the IP address instead of the http://FTP://username@server.com syntax so i did a ping to the server, from my dedicated server to get the ip, then switched the code to use that and it worked thanks for the help ps - if anyone else is looking for something similar - i definitely recommend the FTPClient DLL - great program: http://sourceforge.net/projects/dotnetftpclient/ Quote
sdlangers Posted October 4, 2005 Author Posted October 4, 2005 to see the sample code itself look at: http://sourceforge.net/docman/display_doc.php?docid=22902&group_id=92889 Quote
eakinasila Posted November 25, 2009 Posted November 25, 2009 How to restrict a unix ftp user to its home directory? I want to restrict one ftp user so that it cannot access any other directory on the server other than the home directory assigned to it. It should have full access to its home directory and all its sub-directories. Any help is greatly appreciated. Quote
booriaxy73 Posted December 5, 2009 Posted December 5, 2009 Hi Im trying to transfer all my pictures from my PC to PS3 using Red Kawa. The problem is that i can only copy one file at the time. Is it possible to copy all files in a folder? Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.