John Tipton
John Tipton

Reputation: 195

WinSCP automate file transfer- Should the batch and script file locate in virtual or local directory?

I'm trying to import a CSV file from my local machine to virtual machine (ABC FTP).

Should both of my batch & text file be located in C:\test\Test.txt? which is a virtual machine directory? And having the WinSCP running on local directory (connected to ABC FTP), by double-clicking the batch file on virtual machine, do I trigger WinSCP to import my CSV file from C:\Transfer\ToABCTest\?

My batch file (.bat) is:

"C:\Program Files (x86)\winSCP\winSCP.com" /script="C:\test\Test.txt"

My text file (.txt) is:

option batch abort
option confirm off
open ABCFTP
lcd C:\Transfer\ToABCTest\
get -delete  /test_edi_in/*.txt
close
exit

Upvotes: 0

Views: 581

Answers (1)

Martin Prikryl
Martin Prikryl

Reputation: 202272

It doesn't matter.

Store the scripts wherever you want, as long as the local machine has an access to them.


Though if the local machine has a direct access to the virtual machine folder, it seems like an overkill to use WinSCP/FTP to download files.

So chances are, that I do not understand your question.

Upvotes: 1

Related Questions