$resumeSupport = New-Object -TypeName WinSCP.TransferResumeSupport $resumeSupport.State = 'On' $resumeSupport.Threshold = 1000 $transferOptions = New-Object -TypeName WinSCP.TransferOptions $transferOptions.ResumeSupport = $resumeSupport
However, for the first line i get the following error:
New-Object : A constructor was not found. Cannot find an appropriate constructor for type WinSCP.TransferResumeSupport.
I know this can be done:
$transferOptions = New-Object -TypeName WinSCP.TransferOptions $transferOptions.ResumeSupport.State = 'On' $transferOptions.ResumeSupport.Threshold = 1000