Results 1 to 2 of 2
  1. #1
    user12345 is offline Member
    Join Date
    Mar 2009
    Rep Power

    Question How to use FTP to read files from server?

    Hi All,

    This is my first ever post in Java forums. I am very new to Java.

    My requirement is load data using sql*loader through Java taking files from the local machine. Now my requirement is to take the data files from the FTP server.

    It may be a silly question, but I really do not have any idea how to read the files from FTP server.

    Can someone help me with this issue?

    Thanks in advance.

  2. #2
    logicbug's Avatar
    logicbug is offline Member
    Join Date
    Jan 2009
    The Great White North, eh?
    Rep Power


    This should get you started

    Java Code:
    URL url = new URL(";type=i");
    URLConnection urlc = url.openConnection();
    InputStream is = urlc.getInputStream(); // To download
    OutputStream os = urlc.getOutputStream(); // To upload

Similar Threads

  1. Read and Open *.txt Files? help!!
    By ashton in forum New To Java
    Replies: 9
    Last Post: 11-01-2009, 04:42 PM
  2. How Read and Write XMl files using Java
    By tjs in forum SWT / JFace
    Replies: 0
    Last Post: 02-23-2009, 01:19 PM
  3. Replies: 2
    Last Post: 02-20-2009, 08:13 AM
  4. Saved files are coming back as read-only
    By Manoeuvre in forum Eclipse
    Replies: 0
    Last Post: 11-21-2008, 06:18 PM
  5. [SOLVED] Read/write files using applets
    By coolFrenzi in forum Advanced Java
    Replies: 3
    Last Post: 11-17-2008, 11:45 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts