[11.03] Sudden "No more files..." error

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

User avatar
MaxX
Power Member
Power Member
Posts: 1029
Joined: 2012-03-23, 18:15 UTC
Location: UA

[11.03] Sudden "No more files..." error

Post by *MaxX »

1. Put TC into the folder with spaces. Let it be like this one: "C:\Portable\Total Commander\"
2. Ensure that you have Editor=%COMMANDER_PATH%\AkelPad.exe in wincmd.ini
3. Create the file without extension "C:\Portable\Total". Just the same as the directory, but cut the path on the first space.
4. Now try to hit F4 on any file. See an error message: file not found, path to Akelpad, no more files.

Found this on TC 11.03 (any bit-s) and Win10. Older versions may be affected too, did not test them. This needs fix.
Ukrainian Total Commander Translator. Feedback and discuss.
User avatar
Stefan2
Power Member
Power Member
Posts: 4159
Joined: 2007-09-13, 22:20 UTC
Location: Europa

Re: [11.03] Sudden "No more files..." error

Post by *Stefan2 »

If your %COMMANDER_PATH% contains spaces, quote the whole path

Editor="%COMMANDER_PATH%\AkelPad.exe" "%1"


same as with:
Editor="C:\Portable\Total Commander\AkelPad.exe" "%1"



In wincmd.ini this looks like this (relative path for sub-folder is enough):
Editor=""Tools\NotePad2\notepad2.exe" "%1""
 
User avatar
Sir_SiLvA
Power Member
Power Member
Posts: 3299
Joined: 2003-05-06, 11:46 UTC

Re: [11.03] Sudden "No more files..." error

Post by *Sir_SiLvA »

1. Confirmed

2. Ensure that you have Editor=%COMMANDER_PATH%\AkelPad.exe in wincmd.ini
isnt needed my configed editor:

Code: Select all

Editor=%Commander_Path%\Tools\Text\Win32Pad\TedNPad.exe
3. Also with this strange configuration I cant edit any text-files with F4 as the error msg always pops up instead

Code: Select all

Total Commander
---------------------------
Datei nicht gefunden!

C:\Portable\Total Commander\Tools\Text\Win32Pad\TedNPad.exe 

"Es sind keine weiteren Dateien vorhanden."
---------------------------
Pressing enter on a text file gives me the win default dialog asking which prg to use to open the file
and every internal assiocation doesnt work.


@Stefan2:
1. Editor="%Commander_Path%\Tools\Text\Win32Pad\TedNPad.exe" doesnt change a thing
2. why the unneeded %1 in the editor line :?:
Hoecker sie sind raus!
User avatar
MaxX
Power Member
Power Member
Posts: 1029
Joined: 2012-03-23, 18:15 UTC
Location: UA

Re: [11.03] Sudden "No more files..." error

Post by *MaxX »

Ah. Something more. I forgot to say that double quoting of akelpad.exe path does not change anything. I've tested that too, no difference there.
Ukrainian Total Commander Translator. Feedback and discuss.
User avatar
MaxX
Power Member
Power Member
Posts: 1029
Joined: 2012-03-23, 18:15 UTC
Location: UA

Re: [11.03] Sudden "No more files..." error

Post by *MaxX »

p.s.
I have also got errors on reading .cab files (I have "multiarc.wcx + mscab.exe" installed and configed). I think that it is also has the same reasons...
Ukrainian Total Commander Translator. Feedback and discuss.
User avatar
petermad
Power Member
Power Member
Posts: 14809
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Re: [11.03] Sudden "No more files..." error

Post by *petermad »

2MaxX

Does it work if you don't use %COMMANDER_PATH% ?
I.e:
Editor=C:\Portable\Total Commander\AkelPad.exe
or
Editor="C:\Portable\Total Commander\AkelPad.exe"
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
gdpr deleted 6
Power Member
Power Member
Posts: 872
Joined: 2013-09-04, 14:07 UTC

Re: [11.03] Sudden "No more files..." error

Post by *gdpr deleted 6 »

MaxX wrote: 2024-03-23, 05:41 UTC Ah. Something more. I forgot to say that double quoting of akelpad.exe path does not change anything. I've tested that too, no difference there.
Manually editing the INI file:

Pay utmost attention to the number and placement of double quotes. If you edit the INI file manually, it doesn't work if you place just a "simple" pair of double quotes. Instead, you need to "nest" pairs of double quotes in the Editor INI file setting. It has to look like this in the INI file:

Code: Select all

Editor=""%COMMANDER_PATH%\AkelPad.exe""
Note the placement and the count of the double-quotes - there are 4 double-quote characters in this line.

If you also need to specify the %1 parameter for some reason

Code: Select all

Editor=""%COMMANDER_PATH%\AkelPad.exe" "%1""
(there are 6 double-quote characters in this line)

It seems surrounding the %1 with double-quotes doesn't seem to be necessary (although i haven't tested this exhaustively), so if you are feeling so inclined, you could perhaps also put this in your INI file:

Code: Select all

Editor=""%COMMANDER_PATH%\AkelPad.exe" %1"
(there are 4 double-quote characters in this line; note their placement)

After editing the INI file manually, restart TC to make sure the edited setting(s) really take effect.


Using the configuration dialog:

If you use the config dialog in TC instead of manually editing the INI file, input exactly this in the config dialog:

Code: Select all

"%COMMANDER_PATH%\AkelPad.exe"
Again, pay attention to the placement and count of the double-quote characters here (there are 2 double quotes here)

And with the %1 parameter quoted (the double-quotes surrounding the %1 might not be necessary, though):

Code: Select all

"%COMMANDER_PATH%\AkelPad.exe" "%1"

If you place the double-quotes correctly, it will work.
Last edited by gdpr deleted 6 on 2024-03-23, 21:13 UTC, edited 5 times in total.
User avatar
Sir_SiLvA
Power Member
Power Member
Posts: 3299
Joined: 2003-05-06, 11:46 UTC

Re: [11.03] Sudden "No more files..." error

Post by *Sir_SiLvA »

elgonzo wrote: 2024-03-23, 18:34 UTC

Code: Select all

Editor=""%COMMANDER_PATH%\AkelPad.exe" "%1""
^

the %1 is NOT needed there at all.
Hoecker sie sind raus!
gdpr deleted 6
Power Member
Power Member
Posts: 872
Joined: 2013-09-04, 14:07 UTC

Re: [11.03] Sudden "No more files..." error

Post by *gdpr deleted 6 »

Sir_SiLvA wrote: 2024-03-23, 19:02 UTC the %1 is NOT needed there at all.
You're right. I edited my previous comment.
User avatar
Dalai
Power Member
Power Member
Posts: 9393
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Re: [11.03] Sudden "No more files..." error

Post by *Dalai »

2Sir_SiLvA
When setting the editor via GUI TC adds the "%1" parameter and IIRC there's a reason it does that. Unfortunately I can't remember the specifics. And yes, usually everything works just fine without it.
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
User avatar
Sir_SiLvA
Power Member
Power Member
Posts: 3299
Joined: 2003-05-06, 11:46 UTC

Re: [11.03] Sudden "No more files..." error

Post by *Sir_SiLvA »

Dalai wrote: 2024-03-23, 19:41 UTC 2Sir_SiLvA
When setting the editor via GUI TC adds the "%1" parameter and IIRC there's a reason it does that. Unfortunately I can't remember the specifics. And yes, usually everything works just fine without it.
After 20 years I used the gui and you are right it does so but still there should be no reason to add the %1 imho :?:
Hoecker sie sind raus!
User avatar
petermad
Power Member
Power Member
Posts: 14809
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Re: [11.03] Sudden "No more files..." error

Post by *petermad »

Maybe these explains it:

viewtopic.php?p=437663#p437663
history.txt wrote:07.07.23 Fixed: cm_Edit, or Shift+F4 new file: Opening the editor failed if it was provided in double quotes, e.g. "c:\path\editor.exe" (32/64)
16.06.23 Fixed: F4 edit: On 64-bit Windows, always pass long name (not DOS name) to editor when no parameter is given (use %1 for short DOS name) (32/64)
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
MaxX
Power Member
Power Member
Posts: 1029
Joined: 2012-03-23, 18:15 UTC
Location: UA

Re: [11.03] Sudden "No more files..." error

Post by *MaxX »

Well, trying double+double quoting makes the diffrence but does not answer the main problem.
Are there any similar places to get the same issue? E.g., any packer's paths or anything else...
Ukrainian Total Commander Translator. Feedback and discuss.
User avatar
petermad
Power Member
Power Member
Posts: 14809
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Re: [11.03] Sudden "No more files..." error

Post by *petermad »

Are there any similar places to get the same issue?
Very good question
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
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: [11.03] Sudden "No more files..." error

Post by *ghisler(Author) »

When reading from ini files, Windows removes any surrounding double quotes, e.g.
Editor="%COMMANDER_PATH%\AkelPad.exe" "%1"
-> %COMMANDER_PATH%\AkelPad.exe" "%1

Editor=""%COMMANDER_PATH%\AkelPad.exe" "%1""
-> "%COMMANDER_PATH%\AkelPad.exe" "%1"
Author of Total Commander
https://www.ghisler.com
Post Reply