Hallo,
ich versuche den Inhalt des FTP-Verzeichniss mit folgendem code zu erreichen ( java 1.4.2 als FTP-Server IIS unter windows xp):
client = new FtpClient();
client.openServer("myftpserver", 21);
client.login("myname", "mypass");
client.ascii();
client.cd("/www");
TelnetInputStream t = client.list();
int ch;
StringBuffer buf = new StringBuffer();
while((ch = t.read()) >= 0)
buf.append((char)ch);
client.close();
System.out.println(buf.toString());
} catch(Exception e){
System.out.println(e);
}
ich bekomme das folgende exception:
sun.net.ftp.FtpProtocolException: PORT :
at sun.net.ftp.FtpClient.openDataConnection
(FtpClient.java:381)
kann jemand bitt helfen!!
ich versuche den Inhalt des FTP-Verzeichniss mit folgendem code zu erreichen ( java 1.4.2 als FTP-Server IIS unter windows xp):
client = new FtpClient();
client.openServer("myftpserver", 21);
client.login("myname", "mypass");
client.ascii();
client.cd("/www");
TelnetInputStream t = client.list();
int ch;
StringBuffer buf = new StringBuffer();
while((ch = t.read()) >= 0)
buf.append((char)ch);
client.close();
System.out.println(buf.toString());
} catch(Exception e){
System.out.println(e);
}
ich bekomme das folgende exception:
sun.net.ftp.FtpProtocolException: PORT :
at sun.net.ftp.FtpClient.openDataConnection
(FtpClient.java:381)
kann jemand bitt helfen!!
Comment