Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
6.5k views
in Java FTP by
why use dirDetails()?that list my derectory is empty.

4 Answers

0 votes
by (162k points)
More information required ....

why use dirDetails()?that list my derectory is empty.
0 votes
by
try{
FTPClient fc = new FTPClient("76.76.16.151");
fc.login("admi","hhh");
fc.setConnectMode(FTPConnectMode.PASV);
FTPFile [] files = fc.dirDetails(".");
out.println(files.length);
String fname=null;
for(int i=0; i<files.length; i++){
fname=files[i].getName();
if(files[i].isDir()){
out.println(fname+"derectory<br>");
}
else{
out.println(fname+"<br>");
}
}
0 votes
by
try{
FTPClient fc = new FTPClient("176.176.116.151");
fc.login("admi","hhh");
fc.setConnectMode(FTPConnectMode.PASV);
FTPFile [] files = fc.dirDetails(".");
out.println(files.length);
String fname=null;
for(int i=0; i<files.length; i++){
fname=files[i].getName();
if(files[i].isDir()){
out.println(fname+"derectory<br>");
}
else{
out.println(fname+"<br>");
}
}
0 votes
by (162k points)
So if you login via commandline FTP and type 'dir', what do you get?

Categories

...