Android Question (SOLVED) FTP seems to ignore Uploads with no network

Discussion in 'Android Questions' started by tigrot, Jun 15, 2015.

  1. tigrot

    tigrot Well-Known Member Licensed User

    Hi Everybody,
    this time my issue is with FTP uploads.
    If 3G/4G network is not active or unstable and I start an upload, there is never a callback event. It works very well if connection drops during a started transfer.
    I the first case I'm not able to realise the status of the transfer...
    I'm thinking to switch to HTTPS to gain better control on transfer, (I have already a PHP module to support it) but I'd like to know the reason for this behaviour, since I was never able to see, 'cause of a very high network signal on my side.

    Best regards
    Mauro Zanin
     
  2. Erel

    Erel Administrator Staff Member Licensed User

    You are handling the UploadCompleted event, right?

    The FTP library doesn't have a timeout setting. You can use a timer that will fire after x seconds and will close the connection if it hasn't yet completed.
     
  3. tigrot

    tigrot Well-Known Member Licensed User

    That what I did was to issue a closenow after a certain time elapses without Uploadprogress events. A counter is reset in the event. This solved the issue!
    I whish I could think "multitasking" like you....

    Ciao e grazie
    Mauro
     
Loading...