New environment for wcx_ftp.ini

Here you can propose new features, make suggestions etc.

Moderators: Hacker, petermad, Stefan2, white

User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, petermad.

I explicitly support the request of introducing an additional %COMMANDER_FTP_INI% variable - or whatever the variable name will be. And I admit that the posted code may be considered a dirty little hack which will not work in all situations. It was not meant to be an argument against the requested variable.

Kind regards,
Karl
MX Linux 21.3 64-bit xfce, Total Commander 11.50 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
User avatar
petermad
Power Member
Power Member
Posts: 16118
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

2karlchen
It was not meant to be an argument against the requested variable
I didn't think so, sorry if my report sounded like that. I was just trying to add some extra arguments FOR the requested variable.
License #524 (1994)
Danish Total Commander Translator
TC 11.55rc4 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1393a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
george60120
Junior Member
Junior Member
Posts: 22
Joined: 2011-11-29, 14:40 UTC

Post by *george60120 »

Unfortunately it is not implemented in TC 8 beta 14 :(

@Ghisler

Is it planned for future beta(s) or it is not planned at all?
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50873
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Sorry, it's currently not planned.
Author of Total Commander
https://www.ghisler.com
george60120
Junior Member
Junior Member
Posts: 22
Joined: 2011-11-29, 14:40 UTC

Post by *george60120 »

ghisler(Author) wrote:Sorry, it's currently not planned.
Sad for that :(

Although all members in this thread supports this new environment variable and gave good reasons to implement it, i respect your openion in hope you will change your mind in the near future.
User avatar
petermad
Power Member
Power Member
Posts: 16118
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

:(
License #524 (1994)
Danish Total Commander Translator
TC 11.55rc4 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1393a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
ts4242
Power Member
Power Member
Posts: 2081
Joined: 2004-02-02, 20:08 UTC
Contact:

Post by *ts4242 »

:cry:
absolute0
Junior Member
Junior Member
Posts: 14
Joined: 2011-04-21, 03:25 UTC

Post by *absolute0 »

I also need %COMMANDER_FTP_INI% it is useful like %COMMANDER_INI%
ghisler(Author) wrote:There is no reason for programs to access the wcx_ftp.ini, except perhaps for stealing unencrypted passwords...
If you think starting TC with /f param will make it difficult to know the place of wcx_ftp.ini, here you are a very simple vbscript which will listing all TC instances and the command line used to launch it.

Code: Select all

   Set objWMIService = GetObject("winmgmts:\\.\root\cimv2")
    Set colProcesses = objWMIService.ExecQuery("Select * from Win32_Process " & "Where Name = 'totalcmd.exe'")
    For Each objProcess In colProcesses
        msg = msg & objProcess.CommandLine & vbNewLine
    Next
    
    MsgBox msg
Therefore, a spayware using few lines of code can easily get all wcx_ftp.ini that are not in TC folder or in other place than the one in the registry.
absolute0
Junior Member
Junior Member
Posts: 14
Joined: 2011-04-21, 03:25 UTC

Post by *absolute0 »

@Ghisler

It is very frustrate to ignore your users request specially when it is simple and will not take a lot of time to implement (just one call to SetEnvironmentVariable at TC startup).

You have implemented %Commander_EXE% too fast, why not do the same for %COMMANDER_FTP_INI% - for me, it is much important.

What do you need more to convince you?
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50873
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Sorry, I don't want to clutter the relatively limited environment variable space with mostly unnecessary variables. Just use %COMMANDER_INI%, and if the ftp ini isn't in the same spot, ask the user.
Author of Total Commander
https://www.ghisler.com
User avatar
ts4242
Power Member
Power Member
Posts: 2081
Joined: 2004-02-02, 20:08 UTC
Contact:

Post by *ts4242 »

A workaround could be using a batch file to set %COMMANDER_FTP_INI% then launch TC with it

1- Copy the following code and save it in a text file with extension cmd (change the path of TC and the path/name of wcx_ftp.ini to meet your case)

Code: Select all

Set COMMANDER_FTP_INI=C:\Totalcmd\my_ftp.ini
Start C:\Totalcmd\Totalcmd.exe /f=%COMMANDER_FTP_INI%
2- After saving the file, create a shortcut for it on your desktop.
3- Show property dialog for the shortcut and choose Run: Minimized (to prevent the flicker of the cmd.exe black window when running it )
4- Change the icon of the shortcut to TC's icon

Now, each time TC starts by this shortcut, it will inherit %COMMANDER_FTP_INI% and all programs start from that TC instance will inherit it too.
george60120
Junior Member
Junior Member
Posts: 22
Joined: 2011-11-29, 14:40 UTC

Post by *george60120 »

@ts4242

Thanks, really helpful workaround :)

Is there any way to prevent the flicker of the cmd.exe black window without creating a shortcut to the batch file? (something like a command to make the batch run with hidden window)
User avatar
ts4242
Power Member
Power Member
Posts: 2081
Joined: 2004-02-02, 20:08 UTC
Contact:

Post by *ts4242 »

george60120 wrote:Is there any way to prevent the flicker of the cmd.exe black window without creating a shortcut to the batch file?
I searched for this before and found creating a shortcut is the best solution because other solutions require using external tool or use vbscript to run the batch.

Another solution could be drag the batch file to TC button bar and check the option "Run minimized"
Post Reply