Open aurel-appsthru opened 3 years ago
Can you elaborate on this? I'm not sure how to really implement this pwsh. Can you give me an example of how you would see it working, and a situation where you would use it?
I would like a simple progresbar like this:
$session.add_FileTransferProgress( { FileTransferProgress($_) } )
would need to be implemented in New-WinSCPSession.ps1 before opening the session.
I dont know where the best place for the function would be. (mine looks like this)
function FileTransferProgress
{
param($e)
Write-Progress `
-Id 1 -Activity "Transfering" -Status ("{0:P0} complete:" -f $e.OverallProgress) `
-PercentComplete ($e.OverallProgress * 100)
Write-Progress `
-Id 2 -ParentId 1 -Activity $(([String]$e.FileName).Substring($e.FileName.length - 30,30)) -Status ("{0:P0} complete:" -f $e.FileProgress) `
-PercentComplete ($e.FileProgress * 100)
}
https://winscp.net/eng/docs/library_session_filetransferprogress
Agree - this would be great!
Issue Description
Hello, it would be great if we could add event support like FileTransferred or FileTransferProgress !
https://winscp.net/eng/docs/library_session#events
THX