The timestamp of the moved directory should not change (if you move it within the same file system). But WinSCP does not control that anyhow. The server does. What server is that? What file system? What protocol? Post some logs (including directory listings before and after the move). Do you see the same behaviour in WinSCP GUI?
I am using Session.MoveFile
archive all files that older than a certain date as an archival process. The issue I have is that while it does preserve the file time stamp, it does not preserve the directory timestamp.
Can you advise? The Session.MoveFile
method only has 2 arguments From and To with no way to specify a transfer options variable.
I'd like to use $transferOptions.AddRawSettings("PreserveTimeDirs", "1")
but that does not appear to be an available option for Session.MoveFile
.
Thanks so much!