# Topic "Should be "WinSCP.com" instead of "WinSCP.exe" in the hint for script/batch"

Author Message
Horus
[View user's profile]

Joined: 2014-12-10
Posts: 6
Hi,

In menu "Session" > "Generate session URL/code" > "Script" tab:
* For format "Script file", at the bottom we have the hint:
# "C:\Program Files (x86)\WinSCP\WinSCP.exe" /log="C:\writable\path\to\log\WinSCP.log"
But I suppose it should be WinSCP.com

* For format "Command-line":
There is a hint behind the drop-down menu and there, it's also written WinSCP.exe but I also think it should be WinSCP.com

Have a nice day
martin
[View user's profile]
Joined: 2002-12-10
Posts: 25966
Location: Prague, Czechia
Well, that depends on a context.

If you run this from a batch file, you will typically use winscp.com (as the "batch file" template shows).
But in other contexts, you will typically use the winscp.exe.
Horus
[View user's profile]

Joined: 2014-12-10
Posts: 6
By curiosity, what other contexts do we have?

I remember I've also tried to type the whole command in DOS window but got error. That's why I thought we should always use .com instead of .exe.
martin
[View user's profile]
Joined: 2002-12-10
Posts: 25966
Location: Prague, Czechia
Horus wrote:
By curiosity, what other contexts do we have?

For example any kind tool for task scheduling or automation, like Windows Scheduler or SSIS.
Horus
[View user's profile]

Joined: 2014-12-10
Posts: 6
OK, I see. Normally I would “encapsulate” the commands inside a batch file before calling it in task scheduler so that’s why I don’t use it directly there.

OTOH, I have just tried the same command (or maybe a bit different) with .exe and I didn’t get any error!? That’s weird. I can’t really remember what version I was using when I tested .exe vs .com. Maybe something has been changed between versions.

Anyway, this thread can be closed.

You can post new topics in this forum

## What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!