Re: unable to upload
So do you still need any help?
Instructions for obtaining the session log is in my previous reply.
Instructions for obtaining the session log is in my previous reply.
I am unable to upload a file. The error message the upload was successful but error occurred while setting the permissions and/or timestamp. I set preservetimestamp to false. I am using vb.net. I still get the error. I don't see where I can turn off permissions.
I am unable to upload a file. The error message the upload was successful but error occurred while setting the permissions and/or timestamp. I set preservetimestamp to false. I am using vb.net. I still get the error. I don't see where I can turn off permissions.
Day 2
Any body know how to turn off permission settings on a file upload?
I am unable to upload a file. The error message the upload was successful but error occurred while setting the permissions and/or timestamp. I set preservetimestamp to false. I am using vb.net. I still get the error. I don't see where I can turn off permissions.
Please attach a full session log file showing the problem (using the latest version of WinSCP).
To generate the session log file, setSession.SessionLogPath
. Submit the log with your post as an attachment. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you can mark the attachment as private.
Here is my code. I am unable to find the log file.
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Try
' Setup session options
Dim sessionOptions As New SessionOptions
With sessionOptions
.Protocol = Protocol.Sftp
.HostName = "host"
.UserName = "user"
.Password = "pass"
.PortNumber = 22
.SshHostKeyFingerprint = "ssh-rsa 2048 d5:e9:b2:29:16:a3:09:fb:e8:6d:67:72:be:88:c8:d6"
End With
Using session As New Session
session.SessionLogPath = "p:\comerica\log.xml"
' Connect
session.Open(sessionOptions)
' Upload files
Dim transferOptions As New TransferOptions
transferOptions.TransferMode = TransferMode.Ascii
transferOptions.PreserveTimestamp = False
Dim transferResult As TransferOperationResult
transferResult = session.PutFiles("p:\Comerica\DataVault\ACH\TPEPILOCOMOTVSFTP.EFTCLAIMS 09-06-2017 - Copy.txt", "/To_Comerica/TPEPILOCOMOTVSFTP.txt")
'https://sftp.comerica.com/?token=20079AB7-94AE-11e7-80E2-42F2E966EE8F#/To_Comerica/
' Throw on any error
transferResult.Check()
' Print results
For Each transfer In transferResult.Transfers
Debug.Print("Upload of {0} succeeded", transfer.FileName)
Next
End Using
'Return 0
Catch 'e As Exception
Console.WriteLine("Error: {0}", e)
'Return 1
End Try
End Sub
Please attach a full session log file showing the problem (using the latest version of WinSCP).
To generate the session log file, setSession.SessionLogPath
. Submit the log with your post as an attachment. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you can mark the attachment as private.
Session.SessionLogPath
. Submit the log with your post as an attachment. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you can mark the attachment as private.