On Wed, Aug 20, 2008 at 7:28 PM, Loureiro, Gil <[EMAIL PROTECTED]> wrote:
> I'm trying to create a directory if not exist in the OnLogin event. First
> problem is I'm not able to get session.getFileSystemView() it always returns
> null . To work around I've placed the code on the OnUploadStart where I can
> get it correctly.
What version of FtpServer are you using? The reason for asking it that
I've made a significant change to how Ftplets work in trunk, but after
the M2 release.
If your using trunk, you should be able to get the file system on
onLogin(), but I'm away from Eclipse right now so I can't verify that
for you.
> My problem now is to create a directory inside the users home dir (I get the
> FileObject from the getCurrentDirectory()),when I try to get the dir path I
> get '/', so I don't see how can I create a new dir?
fsView.getFileObject("mynewdir").mkdir() should work.
/niklas