how to copy the directory in to ftp server using java

how to copy the directory in to ftp server using java

how to copy the directory in to ftp server using java ?

View Answers

December 14, 2010 at 3:12 PM

Hello venaktehs

As much as I know,You can do this as follows:

First,Create a directory in the current working directory with the same name (which you wish to copy) as:

issueCommand("MKD"+directoryName);

Change the working directory :

// Here "ftp" is the Object of Ftp

ftp.setDir(directoryName);

Now,if need, You can change the local directory.For example :

ftp.setLocalDir(new File("C:/tmp");

Now you can upload file in your remote directory as follows :

ftp.upload(new File("c:/tmp/test.txt"));

I Hope this Info helps you.









Related Tutorials/Questions & Answers:
how to copy the directory in to ftp server using java
how to copy the directory in to ftp server using java  how to copy the directory in to ftp server using java ?   Hello venaktehs As much... in the current working directory with the same name (which you wish to copy
FTP Server : Create Directory
In this section you will learn how to create directory on FTP server using java
Advertisements
FTP Server : Remove Directory
In this section you will learn how to delete directory on FTP server using java
FTP Server : Change working directory
In this tutorial you will learn how to change working directory on FTP server using java
Change parent directory on ftp server
In this section you will learn how to change the parent directory on FTP server using java
How to implement FTP using java
How to implement FTP using java  Hi, I am a B.tech student and I want to implement FTP using Java to transfer files and exchange files between FTP client and FTP server. Could anyone help me for How to implement FTP using java
Search Directory on Ftp Server
This tutorial describes how to search a specific directory on the server by using java
how to creat ftp server on java
how to creat ftp server on java  ftp server investigation requirment ER diagram flow chart source code
how to creat ftp server on java
how to creat ftp server on java  ftp server investigation requirment ER diagram flow chart source code
how to creat ftp server on java
how to creat ftp server on java  ftp server investigation requirment ER diagram flow chart source code
how to creat ftp server on java
how to creat ftp server on java  ftp server investigation requirment ER diagram flow chart source code
how to creat ftp server on java
how to creat ftp server on java  ftp server investigation requirment ER diagram flow chart source code
how to creat ftp server on java
how to creat ftp server on java  ftp server investigation requirment ER diagram flow chart source code
how to creat ftp server on java
how to creat ftp server on java  ftp server investigation requirment ER diagram flow chart source code
how to creat ftp server on java
how to creat ftp server on java  ftp server investigation requirment ER diagram flow chart source code
Checking Directory existence on Ftp Server
In this section, you will learn how to check existence of a directory on the server by using java
how to upload file using FTP in java
how to upload file using FTP in java  hai, i want to upload file using FTP in java Webservices.. Tel me some Articles Regards Asha
FTP file copy problem? - Java Beginners
FTP file copy problem?  Hi, Can any one tell me how to set file lastModifiedTime after copying files through FTP. I am using commons-net-1.4.1.jar to copy files from local system to server. Eg: local file name ?test.doc
how to copy file from one directory to another in java with examples
how to copy file from one directory to another in java with examples  how to copy file from one directory to another in java with examples? I want... copy from one directory to another in java. Thanks
Java Connect to and FTP Server
Java Connect to and FTP Server  What is the code for Java Connect to and FTP Server? How to establish a connection to FTP server in Java? Thansk... the apache commons library to connect/login to FTP server. Link of complete example
FTP server
FTP server  How to store a series of files in a ftp server using java
Copy Directory or File in Java
Copy Directory in Java      ... how to copy the directory and files into a new directory. In this program, you... the source directory using the list() method and copy one by one
FTP Server : Upload file
This tutorial contains description of file uploading to the FTP server using java
FTP Server : Download file
This tutorial contains description of file downloading from the FTP server using java
FTP Server : List Files and Directories
In this tutorial we will discuss how to list files and directories on FTP server using java
List all directories on FTP Server
In this section you will learn how to list all the directories on FTP server using java
Delete a file from FTP Server
In this section you will learn how to delete file from FTP server using java
How to upload file on FTP Server
How to upload file on FTP Server  In my application there is a requirement of uploading the file on FTP server. How to upload file on FTP Server... is good and can be used in Java applications. Read FTP File Upload in Java for more
Get all file size on FTP Server
In this section we are going to describe how to get size of FTP server files using java
FTP Server: List all files name
This tutorial represents how to list the entire files name on FTP server using java
FTP Programming in Java tutorials with example code
you will learn how to add FTP capabilities in your Java program. You will learn how to create program in Java that connects to FTP server and upload... can also develop Java based program that connects to FTP server and send
ftp server
ftp server  ftp server
ftp server
ftp server  ftp server
ftp server
ftp server  ftp server
FTP Server : Connect and Login
In this tutorial we will discuss how to connect and login in FTP server with java programming
how to copy files from remote location to local using java?
how to copy files from remote location to local using java?  I want to copy all files from shared folder to local. Please help
upload and download files from ftp server using servlet - Ajax
for upload and download files from ftp server using servlet and how to use...upload and download files from ftp server using servlet  Hi,Sir...("Hello FTP Server"); pw.println(""); pw.println("Hello FTP Server
FTP Server
FTP Server  i'm working on ftp server if one client has uploaded a file i need to save the details of the user who has uploaded the file like username,filename & ipaddress using java
File copy from one directory to another in java
File copy from one directory to another in java  I am trying to find... directory in Java. I have to write a program in my application for copying one file from a directory to another directory. How to achieve this? Is there any API
Image uploading in FTP Server
Image uploading in FTP Server  I want to upload images to a ftp server every 1 hour automatically using java..please help
how to copy files from remote to local machine using SFTP SSL in java?
how to copy files from remote to local machine using SFTP SSL in java?  I want to copy files from remote server to local machine using SFTP and SSL in java. Plz help
Java FTP
Java FTP  Hi, Is there any API for using FTP in java? Can anyone share me the sample Java FTP code? Thanks   Hi, There are many FTP... be downloaded from the apache website. View examples of Java FTP at: FTP Server
ftp - Java Beginners
ftp  pls tell me how to connect to a ftp server and copy a file to local machine using java, with UNIX code for copying purpose
FTP Server: Get Buffer size
FTP Server: Get Buffer size This tutorial helps you to get the current internal buffer size on FTP server using java. Get Buffer Size : You can find out... to ftp server result = client.login("admin", "admin"); if (result
How to copy a file
How to copy a file In this section, you will learn how to copy a file using Java IO library. For this, we have declared a function called copyfile() which...;} } The above code makes a copy of the file
Java FTP Client Example
Java FTP Client Example  How to write Java FTP Client Example code? Thanks   Hi, Here is the example code of simple FTP client in Java which downloads image from server FTP Download file example. Thanks
Java FTP Download
Java FTP Download  How to write a program in Java for downloading a file from FTP server? Tell me the good and easy to understand code for Java FTP Download. Thanks   Hi, The easiest way to connect to FTP server
upload files to apache ftp server - Ajax
server using javascript and I don't know how to integrate javascript and java... files to apache ftp server. I am using ajax framework for j2ee.Now I am okay... to login to FTP server " + "using username
Java FTP Connection
Java FTP Connection  I am learning to develop a program in Java. As a learning process I want to make a connection to the FTP server just to check if it works? How to make Java FTP Connection to FTP server hosted in my network
Java FTP Upload
in Java. View the FTP Server : Upload file example for complete code example...Java FTP Upload  Is there any example code for Java FTP Upload? Which is the easy to use Java FTP Upload example program at roseindia.net? Thanks

Ads