Progress Bar shows momentarily using .NET in Powershell 4.0
Progress Bar shows momentarily using .NET in Powershell 4.0
Running in Powershell ISE or in CMD.EXE a progress bar flashes up for a moment. How to prevent this? The script will be run by a scheduler. Not using sync, just $session.PutFiles() and $session.GetFiles() for transfers, all piped to Out-Null.
BTW at https://winscp.net/eng/docs/library_example_listing_files_matching_wildcard this:
should be:
Running in Powershell ISE or in CMD.EXE a progress bar flashes up for a moment. How to prevent this? The script will be run by a scheduler. Not using sync, just $session.PutFiles() and $session.GetFiles() for transfers, all piped to Out-Null.
BTW at https://winscp.net/eng/docs/library_example_listing_files_matching_wildcard this:
foreach ($fileInfo in $directory.Files)
should be:
foreach ($fileInfo in $Files)