Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Re: Async GetFile

There are no asynchronous methods in WinSCP .NET assembly.
You can use multiple instances of Session class in separate threads/tasks.
In the examples, there is a separate Session for each thread/task for both download (downloadSession) and upload (uploadSession). Please check the code again.
nighttrain

Async GetFile

Does WinScp has async methods? So far i do not see.

If not, did anyone tested it like putting OpenSession->GetFile-CloseSession into (C#)Task.Run ? Will it work fine with multiple task like that?

Edit:
I found this link doco: https://winscp.net/eng/docs/library_example_parallel_transfers
Question: why in dl you created one session for all Tasks but for upload you creating separated session in each task. is there really a diffrence?