"Editor for F4"

The behaviour described in the bug report is either by design, or would be far too complex/time-consuming to be changed

Moderators: white, Hacker, petermad, Stefan2

Post Reply
User avatar
Balderstrom
Power Member
Power Member
Posts: 2148
Joined: 2005-10-11, 10:10 UTC

"Editor for F4"

Post by *Balderstrom »

I have been unable to Edit anything from TC's context menu for less than the last day. It took some time to figure out what the error was -- as I was trying to edit from the FTP/context menu and continually got: "File cannot be found."

I realized after much trial and error, and also trying F4 as well as the context menu's that there must be a problem there.

But I believe this particular thing is a bug, as I
  • Cleared out the field for (F4) Editor within config
  • [OK]'d and closed config.
  • Re-opened the Config: "none" was listed (as the F4 editor).
  • used the [>>] arrows to browse back to:
    C:\Program Files\TotalCMD\TOOLS\ChoiceEditor\
  • selected: ChoiceEditor.exe
  • [OK]'d and closed config.

Still cannot edit anything, I have had to manually add quotes around the path.

If I use TC's [>>] browse to select an Editor, if it needs quotes it should be checking for quotes and adding them after validating the string.
One would think, if quotes were needed, they would be automatically added even if you pasted a path into the field.

Interestingly enough - one quote at the beginning of the path is enough to make it work.


This occurs in the RC's as well.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48231
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Could that be a problem with ChoiceEdit only? Can you try the same with other editors, e.g. notepad?
Author of Total Commander
https://www.ghisler.com
User avatar
Balderstrom
Power Member
Power Member
Posts: 2148
Joined: 2005-10-11, 10:10 UTC

Post by *Balderstrom »

I tried with Notepad2, and EmEditor.
Paths:
C:\Program Files\¤EDITors\NotePad2\Notepad2.exe
C:\Program Files\EmEditor\EmEditor.exe
Without manually inserting a quote, none of them will run (With F4 or TC's ContextMenu).

Receive a Total Commander pop-up:

Title: Total Commander [X]
Text:______ File not found!
_________[ OK ]________

Similiarly if I copy Notepad.exe to C:\Program Files\Notepad.exe, it also gets the same pop-up error. Can't test notepad from the WinDir, there's no space in that path.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48231
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Strange, I have just tried that with the editor which I'm using (PFE) by placing it in a directory containing a space, but it loads just fine without any double quote.

Maybe it's Windows-specific? Which Windows version do you use? I tried that on Windows XP SP3.
Author of Total Commander
https://www.ghisler.com
User avatar
Balderstrom
Power Member
Power Member
Posts: 2148
Joined: 2005-10-11, 10:10 UTC

Post by *Balderstrom »

Win2K atm, with WinXP's command (cmd.exe) interpreter. Prolly Win7 before the summer concludes.
*BLINK* TC9 Added WM_COPYDATA and WM_USER queries for scripting.
User avatar
petermad
Power Member
Power Member
Posts: 14913
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

It works fine here - I tried with:

C:\Program Files\metapad\metapad.exe
C:\Program Files\F4Menu\F4Menu.exe
C:\Program Files\ChoiceEditor\ChoiceEditor.exe
C:\Program Files\PlainEdit\PlainEdit.exe

All chosen via the >> button in the Edit/View configuration dialog.
License #524 (1994)
Danish Total Commander Translator
TC 11.03 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1371a
TC 3.50 on Android 6 & 13
Try: TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
Balderstrom
Power Member
Power Member
Posts: 2148
Joined: 2005-10-11, 10:10 UTC

Post by *Balderstrom »

I've found out what caused this, not related to the initial premise.

I installed TC7.03a yesterday or the day before.
(It messed up my Registry settings for TC, which I fixed)

To launch TC7.03 I I use a modified batch .cmd file of the one I use for 7.5+

Code: Select all

@ECHO OFF
SET PATH=%SYS32%;C:\WIN2K;%wuBIN%;%wuBin%\exCMD;%wuBIN%\exDOS;%SYS32%\Wbem
SET TC=%ProgramFiles%\TotalCMD
SET TCmd=%TC%\TotalCMD.exe
SET TCMC=%ProgramFiles%\TotalCMD\TOOLS\TCMC.exe 50
SET APPLOCAL=%USERPROFILE%\Local Settings\Application Data
START "" "%ProgramFiles%\TotalCMD_703\TotalCMD.exe" /i=C:\Program Files\TotalCMD_703\wincmd.ini
The culprit is the last line, and /i=C:\Program Files\TotalCMD_703\wincmd.ini
That wound up creating a file, "C:\Program" -- and TC7.03 was using C:\Program for it's config file.

Which caused some other system oddities which made me go looking for Viruses et al.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48231
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

I see, thanks for the clarification! Indeed you have to put the entire parameter in double quotes if it contains spaces:

START "" "%ProgramFiles%\TotalCMD_703\TotalCMD.exe" "/i=C:\Program Files\TotalCMD_703\wincmd.ini"
Author of Total Commander
https://www.ghisler.com
Post Reply