Hi all forum members...this is my first post here so be gentle..
I'm new into java so i'm experimenting new stuff
I have problem with importing external libraries
I have downloaded jar file from apache commons site and done everything that is need to be done
I imported classpath in windows, I updated build path in Eclipse(added external jar) but this still doesn't work
The method connect(String) is undefined for the type FTPClient...it seems like Eclipse cannot read methods(same problem with methods disconnect, getReplyString, getReplyCode
import org.apache.commons.net.ftp.*; public class FTPClient { public static void main(String[] args) { FTPClient ftpClient = new FTPClient(); try { int reply; ftpClient.connect("ftp.nesto.com"); System.out.print(ftpClient.getReplyString()); reply = ftpClient.getReplyCode(); if(!FTPReply.isPositiveCompletion(reply)) { ftpClient.disconnect(); System.err.println("FTP server refused connection."); System.exit(1); } }catch (IOException ex) { System.out.println("Error: " + ex.getMessage()); ex.printStackTrace(); } } }
What am I doing wrong?
Thanks in advance