Topic "Custom .exe file without installation ?"

Author Message
Cedriic

Guest


Hi there,

Is there a way to create a custom executable (with predefine session) without installation ?

It would be a simple .exe file and the user would just click on it to open the explorer.

Thanks for your help.
Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
Please read documentation. If that does not help, come back.
_________________
Martin Prikryl
Cedriic

Guest


Hello,

With documentation I succeed in creating a WinSCP.exe file by doing this :

1/ I download and install the WinSCP programm with the installation package
2/ I start the WinSCP programm (with french language) and I configure and store a session in the WinSCP.ini file
3/ I make a copy of the WinSCP.exe and WinSCP.ini file in a temporary directory
4/ I open the Resource Hacker programm (ResHack.exe)
5/ I open the WinSCP.exe file from the temporary directory with the Resource Hacker programm
6/ I make a left click on RCData then I choose "Action/add a new resource"
7/ In the dialog box I choose "Open file with new ressource" and I select the WinSCP.ini file from the temporary directory
8/ In the "Resource type" field I write RCDATA
9/ In the "Resource name" field I write WINSCP_SESSION
10/ In the "Resource language" field I don't know what to write... but I would like to choose french language.
11/ Then I click on "add resource" and then I save the WinSCP.exe file and exit the Resource Hacker programm

I go back to my temporary directory and click on the WinSCP.exe file and everything works fine because the session works great... except that the programm is still in english and I would have the programm in french.

What should I do to have the WinSCP executable translated in french ?

In addition I would like to know if there is a way to remove some button like "open a terminal", "Open session in Putty" and "sybchronize local directory with remote directory"

And a last question : is it possible to create a lighter WinSCP.exe file (ie: less than 2 MB) ?

Thanks for your help
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
Cedriic wrote:
What should I do to have the WinSCP executable translated in french ?

Copy also file winscp.fr.

Quote:
In addition I would like to know if there is a way to remove some button like "open a terminal", "Open session in Putty" and "sybchronize local directory with remote directory"

No.

Quote:
And a last question : is it possible to create a lighter WinSCP.exe file (ie: less than 2 MB) ?

Replace your winscp.exe with portable executable. Or see UPX.
Cedriic

Guest


Hello,

Thank you for your fast reply.

As I said I embedded the WinSCP.ini file with the Resource Hacker programm by adding the WinSCP.ini file to a new resource data called WINSCP_SESSION

Quote:
Copy also file winscp.fr


But how to embed the WinSCP.fr file with the Resource Hacker programm ? Should I add the WinSCP.fr file to a new resource data called WINSCP_SOMETHING ?

Quote:
Replace your winscp.exe with portable executable. Or see UPX

I'm confused, because the documentation about embeddind settings says :
Quote:
Note that the portable executable is compressed, so you may have troubles editing it. Use the application which comes as part of an installation package.


Thanks for your help
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
Cedriic wrote:
Quote:
Copy also file winscp.fr


But how to embed the WinSCP.fr file with the Resource Hacker programm ? Should I add the WinSCP.fr file to a new resource data called WINSCP_SOMETHING ?

OK, I've forgot that you want to make single file. It is not possible then to make it localized.

Quote:
Quote:
Replace your winscp.exe with portable executable. Or see UPX

I'm confused, because the documentation about embeddind settings says :
Quote:
Note that the portable executable is compressed, so you may have troubles editing it. Use the application which comes as part of an installation package.

OK, then take your "hacked" file and compress it yourself using UPX.
_________________
Martin Prikryl
Cedriic

Guest


Thank you very much for your help Very Happy

Everything is clear for me now
Gobs
[View user's profile]

Joined: 2015-04-13
Posts: 2
Location: France
Hi,

I create this topic years ago... but I can't recover my account settings because of a no more existing email address.

Anyway since a few years I'm generating custom WinSCP.exe files by inserting INI file with site settings to RCData resource named “WINSCP_SESSION”.

As mentionned in my first post in 2008 here is what I usually do

I'm usually working under Linux but I'm using a virtual machine with Windows 7 64 bits to create the custom WinSCP.exe file.

1/ I download and install the WinSCP programm with the installation package
2/ I start the WinSCP programm and I configure and store a session in the WinSCP.ini file
3/ I make a copy of the WinSCP.exe and WinSCP.ini file in a temporary directory
4/ I open the Resource Hacker programm (ResHack.exe)
5/ I open the WinSCP.exe file from the temporary directory with the Resource Hacker programm
6/ I make a left click on RCData then I choose "Action/add a new resource"
7/ In the dialog box I choose "Open file with new ressource" and I select the WinSCP.ini file from the temporary directory
8/ In the "Resource type" field I write RCDATA
9/ In the "Resource name" field I write WINSCP_SESSION
10/ Then I click on "add resource" and then I save the WinSCP.exe file and exit the Resource Hacker programm

I proceed like above since 2008 and everything is fine.

I remember that I have made a few custom WinSCP.exe files a few month ago without any problems.

So I tried to do it again with the latest version of WinSCP (WinSCP 5.7.1).

But as I click on the custom WinSCP.exe file there is only "New Site" in the GUI. Normally the session described in the WinSCP.ini file should open.

Another new behavior is that a WinSCP.ini file is generated at the same level of the custom WinSCP.exe file.

I have opened the custom WinSCP.exe file (as an archive under Linux) to check it and the WINSCP_SESSION informations have been correctly added to the custom WinSCP.exe file.

Thanks for your help
Gobs
[View user's profile]

Joined: 2015-04-13
Posts: 2
Location: France
Embedding WinSCP.ini file in the WinSCP.exe file works with WinSCP 5.1.0

As I click on the custom WinSCP.exe the session described in the WinSCP.ini file open normally.

But a WinSCP.ini file is still generated at the same level of the custom WinSCP.exe file.

I would like to use the latest WinSCP version because of security issues with older versions...

Thanks for your help
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
Thanks for your report.

This bug has been added to the tracker:
http://winscp.net/tracker/show_bug.cgi?id=1311

I'm sending you an email with a development version of WinSCP to address you have used to register on this forum.
Advertisements

You can post new topics in this forum






Search Site

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!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License