Home Forums ActiveX components Xceed FTP for ActiveX Aborting a transfer sometimes hangs the ActiveX

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • User (Old forums)
    Member
    Post count: 23064
    #42827 |

    Hello,

    We’re using the library for a little upload utility in our software as well as the basis for a full FTP client. In both cases we have big issues aborting transfers. This does not happen every time, but it’s pretty frequent that when setting the “Abort” property of the ActiveX, the “SendFile” function will just hang and never return.

    Once this happens, we pretty much can’t do anything other than close the app and restart… Sometimes, setting “Abort” to true several times will make it unlock, but most of the time it has no effect. If we call anything on the ActiveX at this point we get an exception that says the ActiveX is already performing a call.

    Any idea? I just downloaded the latest update for the ActiveX version and the issue is the same.

    Imported from legacy forums. Posted by Alex (had 887 views)

    Diane [Xceed]
    Moderator
    Post count: 1353

    Hi Alex,

    When you perform your transfers, is the BackgroundProcessing property set to true or false?

     

    Imported from legacy forums. Posted by Diane [Xceed] (had 181 views)

    User (Old forums)
    Member
    Post count: 23064

    We never touched that property and from what I understand it is set to FALSE by default. Should I change that to true?

    Here’s a bit more info. We are using the ActiveX on a VB.NET form which has a “Cancel” button while the ActiveX is busy transferring files. We are using the “FileTransferStatus” event to update our UI with a progress bar, byte totals, time estimate, average xfer speed and all that. When we use the “Cancel” we simply set the “Abort” property of the ActiveX to true… This should, from our understanding, abort the current transfer. We stop getting “FileTransferStatus” events at that time so I’m assuming it works, but then again, the ActiveX never exits the “sendFile” function at all.

    We also have a case (on the boss’ machine) where sendFile just blocks and never comes back without any abortion of any kind… It just hangs in there, never sending any FileTransferStatus events, it’s just hung and doesn’t do anything. On that machine, we can reproduce this time and time again, it simply never works. We can use Cancel but then the ActiveX starts spewing unintelligible exceptions where the Exception.Message is random garbage and the ActiveX is just trashed from then on until we restart the application. 

    The Abort issue appears to happen on all machines, but its not systematic… It’s maybe 1 out of 2-3 times or so.

    Imported from legacy forums. Posted by Alex (had 247 views)

    Diane [Xceed]
    Moderator
    Post count: 1353

    Hi Alex,

    When the BackgroundProcessing property is set to false, the SendFile() will keep control until it returns, this might prevent your user interface to run and give the illusion that the application is hung.

    It might be a better design to run the FTP operations in the background so that your user interface continues to run and process messages.

    Be aware that when the BackgroundProcessing property is set to true, it will make SendFile() return immediately. The ProcessCompleted event will be triggered when the operation has completed.

    For the case on your boss’s machine that hangs:

    Can you set the CommandLogFilename property so the communication with the FTP server is logged. Then, can you send us the log of the session that is giving you problems so we can analyze it?

       myFtpClient.CommandLogFilename = “D:\Log\XceedFtp.log”

     

    Imported from legacy forums. Posted by Diane [Xceed] (had 1237 views)

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.