FTP Plugin in Servoy

Hi there,

I would like to know how I could do FTP files to a server from within Servoy.

I have experience using FTPit plugin in FMP.

Please shed some lights.

Thanks

Hameed

Hi there,

If there is no FTP plugin currently in servoy, can I find some third party FTP plugins? Can you please direct me in finding and installing it?

Will there be a FTP support in servoy in the near future?

I really need this functionality since I supposed to use the FTP functionality in many of my solutions.

I hope FTP support in servoy is quite easily acheivable

Hameed

Sounds like a job for a bean:

http://www.jfind.com/listings/563.shtml

  • david

Hi david,

I downloaded that bean and put into the bean directory. The bean appeared in the bean list in the developer. But when I dragged into the layout, it did not have any properties and I was not able to proceed.

do we have a detailed documentation for how to use the bean and plugins?
also how to develop them for servoy?

Thanks for your help.

Hameed

First that ftpbean.jar wasn’t jarred right. I attached a new one for you.

For a small example, place the FtpBean on youre form.
then make a method: (rename the “bean_822” to youre name!)

elements.bean_822.ftpConnect(“ftp.cs.cuhk.edu.hk”, “anonymous”, “citidancer@hongkong.com”);
var dircontent = elements.bean_822.getDirectoryContent();
while(dircontent.next())
{
application.output(dircontent.getName())
}

and you will see the root list.

to know what you can do on the bean and its result you have to look into the docs of the ftpbean.

for example the getDirectoryContent gives a FtpListResult object and in the docs of the ftplistresult you can see that it has the methods next() and getName()

Hi Johan,

Thanks for your help. It worked great. I love it. I tried to list a directory and and was able to delete a file from my FTP site. I am going to try out all other functions.

The only litte issue is I could not supply a name to the bean. there is not name property. The bean listed in the method editor as bean_108

thanks again.

Hameed

That you can’t set a name with a non gui bean is a limitation at this time.

That’s fine. I could live with the default name of the bean.

Another question. How can I control the error messages returned by the bean?

For example, I am trying to delete a file from the FTP server. It works when the file exists in the server. But it throws an error (exception) when the file I am trying to delete does not exists. How can I try/catch exceptions? (ErrorCapture = true does not seems to be working)

Thanks

Hameed

hmm. I just played around with the ftp bean and could not get it to work because I seem to miss at least one component.

The only bean I see is the FTPListresult. I have no access to ftpConnect?

Any ideas/experiences anyone?

Thanks
Patrick

where did you get the bean from? (the url that is given?)
I believe that jar wasn’t jarred right (see my text above)
You need to have the jar i made. But currently there is a problem with attachements in this forum. It’s being worked on.

Thank you! I will wait until the attachment issue is fixed.

Is every one aware of the http (file/multipart) post supported by the http plugin?

No? can you explain?

Well the http plugin can post the way a html tag can post a file to a server page.

Johan: could you place that re-jared FTP bean somewhere where we can download it?

Thanks
Patrick

i have seem to lost my copy i made.
Does anybody else have that jar? Just send it to me and i will set it up for everybody to download.

you can download it from here from now on:
http://downloads.servoy.com/downloads/b … tpbean.jar