Hi,

I'm using the M2 release... will download the last trunk and build it.

With fsView.getFileObject("mynewdir").mkdir() all works.

Thanks, regards,

Cumprimentos,
Loureiro, Gil
Document Engineering Manager
Document Services
_________________________________________
Edinfor - a LogicaCMG company
Rua Particular da EDP (à rua cidade Goa nº11), 2685 Sacavém
Portugal
M: +351 93 741 8888
E: [EMAIL PROTECTED]
www.edinfor.logicacmg.com
-----Original Message-----
From: Niklas Gustavsson [mailto:[EMAIL PROTECTED] 
Sent: quinta-feira, 21 de Agosto de 2008 7:45
To: [email protected]
Subject: Re: [ftplet] Create a directory in the OnLogin event

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


This e-mail and any attachment is for authorised use by the intended 
recipient(s) only. It may contain proprietary material, confidential 
information and/or be subject to legal privilege. It should not be copied, 
disclosed to, retained or used by, any other party. If you are not an intended 
recipient then please promptly delete this e-mail and any attachment and all 
copies and inform the sender. Thank you.


Reply via email to