| Dart Home | PowerTCP FTP for .NET | Custom Development | Reply | PowerTCP FTP for .NET Topics | Forums |
| Author | Forum: PowerTCP FTP for .NET Topic: How do I download multiple files asynchornously...? |
| TJ From: Columbus, OH USA Posts: 15 Member Since: 06/04/04 |
posted June 4, 2004 12:37 AM Hi. I am using FTP for .NET. I would like to download mulitple files using BeginGet method. If I call BeginGet method sequentially like... BeginGet(filename1,localfilename1,null); BeginGet(filename2,localfilename2,null); BeginGet(filename3,localfilename3,null); BeginGet(filename4,localfilename4,null); like docs says, it throws BusyException error at filename2. How do I handle this one?. Is there any elegant way to download multiple files asynchronously? Also I need to show file transferring information by using Dialog box.... Any suggestion and code examples would be greatly appreciated. Thanks... |
Tony Priest![]() From: Utica, NY USA Posts: 8466 Member Since: 04/11/00 |
posted June 4, 2004 10:12 AM You would have to use seperate FTP objects for each asynchronous transfer. See the TransferManager sample for a working example. |
| TJ From: Columbus, OH USA Posts: 15 Member Since: 06/04/04 |
posted June 4, 2004 4:50 PM Hi. Thanks. I just tried out the examples. It seems like to me that directory uploading/download is not supported by the TransferManager example, isn't it? Or...am I missing something .? I just tried to download directory after put the remote filename as "example/*" , "example/" or "example"....It seems like not working. Thanks again. |
Tony Priest![]() From: Utica, NY USA Posts: 8466 Member Since: 04/11/00 |
posted June 4, 2004 4:52 PM It wasn't designed to do that. It's supposed to be a single file. |
| TJ From: Columbus, OH USA Posts: 15 Member Since: 06/04/04 |
posted June 5, 2004 5:25 PM Hi, Tony. I followed the logic like Transfer Manager Example. One thing different is that I made one dialog box... Here is what I did... Download(...) { TransferDialog td = new TransferDialog(); td.Show(); for(int i = 0; i < 5; i++) { ftpTransfer = new Ftp(); ... ... ...Here is some login setting; td.SetFTP(ftpTransfer); } } If you look at the SetFTP.... Here is the code.. public void SetFTP(Dart.PowerTCP.Ftp.Ftp ftp) { try { lvi.SubItems.Add(remoteFilename); lvi.SubItems.Add(pathLocation); lvi.SubItems.Add(""); lvi.SubItems.Add(""); lvi.Tag = ftp; TransferList.Items.Add(lvi); } catch(Exception ex) { MessageBox.Show(ex.Message); } } The problem is that...when showing transfer information on each ftp object in Listbox, it seems like that transfer information wasn't displayed correctly for each ftp instance in each item in ListBox....It seems....transfer information was overlapped in only one item in Listbox....... It is hard to explain...I hope you understand what I am trying to say... Thanks. |
Tony Priest![]() From: Utica, NY USA Posts: 8466 Member Since: 04/11/00 |
posted June 7, 2004 9:26 AM Unfortunately we can't analyze code of this extent on the forum. This is why we provide sample code, to give you a working example to get you started. If you are unable to determine why the sample works and your code doesn't, then please contact support@dart.com to discuss other support options. |
| Reply | PowerTCP FTP for .NET Topics | Forums |
This site is powered by
PowerTCP WebServer for ActiveX
|