View Single Post
Old 09-30-2014, 01:23 PM
secureus secureus is offline
Registered User
Join Date: Sep 2014
Posts: 14
Clarification on sfxcl.exe

From .Net Application, I am doing the File Transfer using sfxcl.exe
Below code works great. I have two questions to clarify.

1) Variable : strBatchFile has absolute file path. It has complete file path. If we installed SecureFx on 64 bit OS,whether the file path will be on C:\Program Files (x86)\
or, C:\Program Files\

2) Can i carry sfxcl.exe in my Project directory and run the application , assuming that SecureFX might have installed or might not installed.

Dim sSFTP As String = String.Empty
            sSFTP = "sftp://" & strUserName & ":" & strPassword & "@" & strHostName & ":" & iPort & strDestPath

            Dim strBatchFile As String = String.Empty
            strBatchFile = "C:\Program Files (x86)\VanDyke Software\Clients\sfxcl.exe"

            Dim proc As New System.Diagnostics.Process()
            proc.StartInfo.UseShellExecute = False
            proc.StartInfo.FileName = strBatchFile
            '            proc.StartInfo.Arguments = String.Format("{0},{1}", strSourceFile, sSFTP)
            proc.StartInfo.Arguments = String.Format("""{0}"" {1}", strSourceFile, sSFTP)

            proc.StartInfo.CreateNoWindow = True
            proc.StartInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden
Reply With Quote