• If you want the package to keep going then you cannot fail the Task. I looked up the exceptions that can be thrown by the DownloadFile method and you'll likely get a WebException. I would add a second catch block that traps for WebException. If you can recreate the error then capture the error message. If the message is standard then you can check for it in your new catch block, and then retry the download if it was in fact a timeout.

    Pseudocode:

    Try

    Try

    Call download file method

    Set Task result to Success

    Catch WebException

    If error message indicates timeout

    Call download file method again

    Set Task result to Success

    Else rethrow error

    End Try

    Catch

    Set Task result to Failed

    End Try

    Edit: adjust Try indentation

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato