From: Huub P. <hu...@tr...> - 2005-03-11 16:23:44
|
Here we go.. I attached a working example that uses Net::FTP with a nice progress bar, without the need of using threads. The GUI is generated with wxGlade (can send the sourcefile to on request) and I tried to document my code a bit so I hope it's clear enough ;-) The whole thing can be extended with loads of other functions but this is just to show a working progress bar when uploading a single file. One could easily alter it to use a wxProgressDialog that gives a nice Cancel function. Bear in mind I tested and created this on Win32 but I can't see anything why it shouldn't work on any other platform. Always curious for some feedback! Regards, Huub Peters. ----- Original Message ----- From: "Huub Peters" <hu...@tr...> To: <mat...@li...>; "bofh" <bo...@af...> Cc: "wxperl-users" <wxp...@li...> Sent: Friday, March 11, 2005 9:16 AM Subject: Re: Re:[wxperl-users] wxFTP and progress information I created that functionality using Net::FTP in one of my apps a while ago. I'll extract the necessary code today and post a working example. Please be patient for a few hours :-) Regards, Huub Peters. ----- Original Message ----- From: <mat...@li...> To: "bofh" <bo...@af...> Cc: "wxperl-users" <wxp...@li...> Sent: Friday, March 11, 2005 9:10 AM Subject: Re:[wxperl-users] wxFTP and progress information Hello, > I need create a program which will be used by various people to upload > rather large files (~ 50Mb) to a server. I've been thinking of using > either ftp or rsync. > > At the moment I'm looking into the ftp option. I have 2 questions: > > 1) Has wxFTP been wrapped? No, and it will not (by me). LWP or Net::FTP or any other Perl module for handling FTP is surely far superior to wxFTP. > 2) Is it possible to get some feedback from the module as to the status > of the upload (eg, the amount sent so far / percent done so far) which > would then be displayed to the user using a wxGauge type widget. It all depends from the module, of corse. > I'm guessing that I'll need to run 2 threads, one to update the GUI and > one to handle the ftp conversation. If (2) is possible, would running > multi-threaded cause any problems? I do not know if anybody has written a multi threaded application with wxPerl. I think using two threads is the best approach. Regards Mattia ____________________________________________________________ 6X velocizzare la tua navigazione a 56k? 6X Web Accelerator di Libero! Scaricalo su INTERNET GRATIS 6X http://www.libero.it ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_ide95&alloc_id396&op=ick _______________________________________________ wxperl-users mailing list wxp...@li... https://lists.sourceforge.net/lists/listinfo/wxperl-users ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click _______________________________________________ wxperl-users mailing list wxp...@li... https://lists.sourceforge.net/lists/listinfo/wxperl-users |