How to Move  a file from one Directory to another directory.

Hi All
i am having a Java standlone Application reqiurements are
1---->Connection pool To be Created.
2---->Using Thread to read Multiple Files Simulatneously.
3----->After Reading Those file I have to Move it to another folder.
Plz help me.If possible give me sample code .
I am in deep trouble for this project.

Use java.io.File.renameTo(...) (look it up in the API documentation).
Renaming a file doesn't work if you're trying to move files from one disk to another disk. In that case, you have to copy the file and delete the original.

Similar Messages

  • How to move SQL database from one location to another location i.e. from C' drive to D' drive

    Hi, How to move SQL database from one location to another location i.e. from C' drive to D' drive ? please share some link.
    Thanks and Regards, Rangnath Mali

    Hi Rangnath,
    According to your description, my understanding is that you want to move databased from C drive to D drive.
    You can detach Database so that the files become independent, cut and paste the files from source to destination and attach again.
    There are two similar posts for your reference:
    http://mssqltalks.wordpress.com/2013/02/28/how-to-move-database-files-from-one-drive-to-another-or-from-one-location-to-another-in-sql-server/
    http://stackoverflow.com/questions/6584938/move-sql-server-2008-database-files-to-a-new-folder-location
    Best Regards,
    Wendy
    Wendy Li
    TechNet Community Support

  • How do you copy files from one user to another

    How do you copy files from one user to another user on the same machine?

    open your home folder in finder move file to public, log into other account, click the go tab on the finder menu, select computer, your hard drive (Macintosh HD Default)>Users, the origonal user> public and drag that file to your specified folder.
    hope it works
    Craig.

  • Move a file from one lacation to another in FTP

    Hi Experts,
    i have scenario were i have to move a file from one location to another in a FTP the source and the Target  structure are same can we go  with only configuration(ID) why because there is no mapping done but i have dbout when we create a sender agreement,receiver agreemant we need to mention the Message Interface is there any way to skip the IR(Design) part
    Do provide inputs
    Thanks,
    Sampath

    hi ,
      you can skip your IR part. follow this blog
    /people/william.li/blog/2006/09/08/how-to-send-any-data-even-binary-through-xi-without-using-the-integration-repository
    /people/shabarish.vijayakumar/blog/2006/04/03/xi-in-the-role-of-a-ftp
    Edited by: Robin on Jan 20, 2009 11:50 AM

  • How do I transfer files from one computer to another without using cables??

    How do I transfer files from one computer to another without using cables?

    Wifi network
    Email
    Thumb Drive
    Online storage such as, iCloud Google Docs, SkyDrive, etc.

  • How to move a report from one account to another account

    Dear all ,
    How to move a reports from one account to another account.
    These are reports sent automatically. Unfortunately, I do not know where to find them and how to export to another account.
    Puru

    Hi,
    You can use the Transaction SCC1 to move the data from One Client to Another Client for a Client dependent table.
    The data should be present in a Transport and you can import to Transport to any client using SCC1.
    Contact the Basis team to know how to use SCC1.
    Regards,
    Aj

  • How to transfer iweb files from one mac to another?

    How to transfer iweb files from one mac to another?
    I have a macbookpro, and I am planing to transfer my iweb data to a new imac, is this possiable and will everything transfer over properly? Will I have problems doing this and how can i do this?

    thank you very much!
    another question,
    if i were to use mobil me to publish my site (at this time i use ftp) will i have the ability to have an outside programer log into my mobil me account and adjust things around in my html codes or add things to my site without iweb? at this time i use ftp and transfer my files from cyberduck to my hosting company. I am new and not very firmilure with the files in my hosting company, so i have help sometimes from a programer that fixes my html codes sometimes for example this page of my site i had someone help me with...
    http://www.sylvartfloraldesigns.com/SylvartFloral_Designs/ScheduleConsultation.html
    will i have the option to do this through mobil me and have someone help me from an outside source, log into my mobil me account and have them adjust things for me?

  • OpenScript: 1.     How to move the scripts from one location to another location. in OpenScript; Copy, paste or Import, export

    How to move the scripts from one location to another location. Copy, paste or Import, export

    Both way you can do.. Difference is - if you copy paste to another folder script dependencies will not move with the same( ie Assets added), whereas if you export and import the script all dependencies will be correlated automatically

  • How to move database objects from one user to another user

    Could someone help how to move database objects from one user to another user
    Thanks in advance

    Thanks a lot for the reply.
    Actually I wanted to know whether there is any command to change the owner ship of the table.
    For ex table1 belongs to user1. can the owner of table1 to be changed to owner2.
    directly using an oracle command. I knew that it can be done using import and export, since the table was 200 million thought the rename command would be faster instead of import and export.
    Thanks Billy for letting me know that it is not possible using oracle query.

  • Move stickie file from one mac to another, move stickie file from one mac to another, How do I move stickie file from one mac to another

    How do you transfer the stickie data file from one mac to another?

    I think this is the file -
    In (hard drive) > Users > yourhomefolder (the one with the house icon) > Library, look for a loose file named StickiesDatabase
    Copying that file to the same location on the new machine (and replacing the file there now) should move the notes. It is probably a good idea that both machines be running the same OS X version.

  • How to move a file from a page to another one in a wiki?

    Is it possible to move a file from a page to another one in a wiki (wiki server 4)?

    Files uploaded via "+" button and "Upload File to "My wiki name"" can be moved just like normal wiki pages by clicking the "sprocket" button and selecting "Move to Wiki"
    Fils attached via the "paperclip" button when editing a page, must be downloaded first, deleted from the initial page and reattached to the new page.

  • How do i transfer files from one mac to another?

    how do i transfer my files from one mac to another mac?

    I normally use an External Hard Drive or Flash Drive for moving files from both Mac's and PC's, but if you want to move from an old Mac to a new one see > How to use Migration Assistant to transfer files from another Mac

  • How to move iMovie project from one computer to another

    I have been working on an iMovie 09 project on my desktop at home.
    Now I want to work on the same project on my computer at work.
    How can I move the project from one computer to another?   What I've already tried was to make a duplicate copy of the project and then use a thumb drive to move that to another computer.   It didn't work.
    Thanks for your help.

    Hello James Snedeker,
    After reviewing your post, it sounds like you want to move a file to another disk. I would recommend that you read this article, it may be able to help the issue.
    iMovie: How to Save Projects to Another Hard Disk
    To copy an iMovie project to another disk:
    1. Quit iMovie if it is open. 
    2. Locate the project folder in the Finder.
    3. Drag the project folder to the other disk.
    Note: You must move the complete project folder, intact, to the other disk in order to successfully copy the project. The project folder has the same name as the project listed in the iMovie window. This folder includes the iMovie project file, as well as a Media folder, which contains all of the clips associated with this project. If you don't copy all of these items, the project may no longer be readable in iMovie.
    Once you have copied the project, try opening it in iMovie to ensure that it copied to the other disk successfully.
    Thanks for using Apple Support Communities.
    Have a nice day,
    Mario

  • How to move an instance from one activity to another

    Hi all,
    Is it possible to move an instance from one activity to another using an external process? Is it possible to do this with PAPI and pass parameters to the instance in order to determine the instance's flow?
    Regards

    Yes it is possible using PAPI. I have just used PAPI to create instances . I have not tried the requirement which you want. But as per my knowledge it can be done.
    Good Luck
    Right Chord

  • How to send doc files from one system to another using XI

    Hi All,
    I have a requirement to pick the word doc files from one file system and send these word document files to ECC system place in ECC application server.Can we achieve this requirement using XI. If so how we can do this. also let me know can we convert these doc files into proxy and send to ECC?. Please let me know. Thanks.
    Regards,
    Rajesh

    Yes You Can
    XI Converts Unstructured data(That is non -XML)Type- in your case word doc and maps it to Target structure.
    You can either use content conversion
    /people/venkat.donela/blog/2005/03/02/introduction-to-simplefile-xi-filescenario-and-complete-walk-through-for-starterspart1
    /people/venkat.donela/blog/2005/03/03/introduction-to-simple-file-xi-filescenario-and-complete-walk-through-for-starterspart2
    /people/venkat.donela/blog/2005/06/08/how-to-send-a-flat-file-with-various-field-lengths-and-variable-substructures-to-xi-30
    /people/anish.abraham2/blog/2005/06/08/content-conversion-patternrandom-content-in-input-file
    /people/shabarish.vijayakumar/blog/2005/08/17/nab-the-tab-file-adapter
    /people/jeyakumar.muthu2/blog/2005/11/29/file-content-conversion-for-unequal-number-of-columns
    /people/shabarish.vijayakumar/blog/2006/02/27/content-conversion-the-key-field-problem
    /people/michal.krawczyk2/blog/2004/12/15/how-to-send-a-flat-file-with-fixed-lengths-to-xi-30-using-a-central-file-adapter
    You can either built a adaptermodule for the same(U nedd to have Some Java knowledge)
    You can also convert without creating any objects in integration directory link for the same is
    /people/william.li/blog/2006/09/08/how-to-send-any-data-even-binary-through-xi-without-using-the-integration-repository
    ***********Please Reward Points If find Helpful*********

Maybe you are looking for