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

Xeix

Thanks a lot Martin, I've been torturing google :-) and I was already seeing that I had to change my strategy
Xeix

Transfer Properties (Size and Timestamp)

Hi,

In a PowerShell script I would be interested to get the size and timestamp of the transferred file, in that moment I have the name.
$transferResult = $session.GetFiles($remotePath, $localPath, $False, $transferOptions)

   
        foreach ($transfer in $transferResult.Transfers)
        {
            if ($transfer.Error -eq $Null)
            {
                $session.MoveFile($transfer.FileName,$Nou)
                Write-Host "Upload of $($transfer.FileName) succeeded, moving to backup " +  $transfer.FileName + ' Date: ' + [b]$transfer.xxxxxx[/b] + ' Size: ' + [b]$transfer.Size[/b]


Is possible? In the Log file they are:
. 2018-11-20 14:02:52.866 Preserving timestamp [2018-10-24T08:07:19.000Z]
. 2018-11-20 14:02:52.882 Transfer done: '/inbox/File.pdf' => '\\server01\G25277203\File.pdf' [150661]


Many thanks in advance,
Xavier Caros