strange 'file not found' error using external editor

English support forum

Moderators: Hacker, petermad, Stefan2, white

Post Reply
User avatar
Sheepdog
Power Member
Power Member
Posts: 5150
Joined: 2003-12-18, 21:44 UTC
Location: Berlin, Germany
Contact:

strange 'file not found' error using external editor

Post by *Sheepdog »

Hi all,
It occurs here a very strange error with external editor configuration.

I got my editor in the following path:

E:\Beta1 6.5\AddOn\Textpad\Textpad.exe

When I browse from within TC to this path and select Textpad and then try to use [F4] i got a "File not found" error.

Adding quotatation marks in the wincmd.ini to
editor="E:\Beta1 6.5\AddOn\Textpad\Textpad.exe"
does not help.

Using
editor=%Commander_path%\AddOn\Textpad\Textpad.exe
editor="%Commander_path%\AddOn\Textpad\Textpad.exe"


Does not help neither.

But if I add two quotation marks:
editor=""%Commander_path%\AddOn\Textpad\Textpad.exe""
it works fine.

I did copy the whole installation to all of my drives. Then I found out that I need the double quotation marks only on drive C:\ and E:\ and with another XP-Installation only on E:\. On all other drives the editor works without any quotation marks.

I'm using mostly FAT32, but on one drive NTFS (it's my L:\).

Does anyone have an idea what could cause such strange behavior?

BTW: I did check that each installation started with it's own wincmd.ini and the correct path.

sheepdog
Last edited by Sheepdog on 2005-02-14, 23:04 UTC, edited 2 times in total.
"A common mistake that people make when trying to design something
completely foolproof is to underestimate the ingenuity of complete fools."
Douglas Adams
User avatar
Clo
Moderator
Moderator
Posts: 5731
Joined: 2003-12-02, 19:01 UTC
Location: Bordeaux, France
Contact:

The dot--- ??

Post by *Clo »

2Sheepdog
:) Hi Stefan !
editor="E:\Beta1 6.5\AddOn\Textpad\Textpad.exe"
- What about the dot in the dir-name ?
- I avoid always this kind of name, I use rather a dash “ - ”…
- Just an idea.

:mrgreen:  VG
Claude
Clo
#31505 Traducteur Français de TC French translator Aide en Français Tutoriels Français English Tutorials
User avatar
Sheepdog
Power Member
Power Member
Posts: 5150
Joined: 2003-12-18, 21:44 UTC
Location: Berlin, Germany
Contact:

Re: The dot--- ??

Post by *Sheepdog »

Clo wrote:- What about the dot in the dir-name ?
I guess it is something with the number space number that makes the trouble.

Neverthless I do not understand why TC loads the editor if the path is enclosed into two pairs of quotation marks while he refuses with only one.

And more strange: Why does TC load the editor on some drives with the same name of the folder?

puzzled

sheepdog
"A common mistake that people make when trying to design something
completely foolproof is to underestimate the ingenuity of complete fools."
Douglas Adams
User avatar
Clo
Moderator
Moderator
Posts: 5731
Joined: 2003-12-02, 19:01 UTC
Location: Bordeaux, France
Contact:

Old habit---

Post by *Clo »

2Sheepdog
• Like I told you ages ago, we resigned XP under FAT32 @home, because some behaviours in the same painting…
- I avoid both space(s) and dot(s) in the path and the filename, an old habit from DOS / 3.1 :P
- What does happen if you rename the folders like this (I mean : without space and dot) ?

:mrgreen: VG
Claude
Clo
Last edited by Clo on 2005-02-13, 05:00 UTC, edited 1 time in total.
#31505 Traducteur Français de TC French translator Aide en Français Tutoriels Français English Tutorials
User avatar
Sheepdog
Power Member
Power Member
Posts: 5150
Joined: 2003-12-18, 21:44 UTC
Location: Berlin, Germany
Contact:

Re: Old habit---

Post by *Sheepdog »

Clo wrote:- What does happens if you rename the folders like this (I mean : without space and dot) ?
The editor is loaded. But that's not the point.

I don't want to find a way how it works ( I already know: Two Pairs of quotation marks).

I just want to find out why it does not work with the given configuration.

sheepdog
"A common mistake that people make when trying to design something
completely foolproof is to underestimate the ingenuity of complete fools."
Douglas Adams
icfu
Power Member
Power Member
Posts: 6052
Joined: 2003-09-10, 18:33 UTC

Post by *icfu »

I suggest using Process Explorer and checking the command line of the external editor after calling it with the double quotation marks on the "strange" drives and one time without on the "normal" drives, maybe this helps finding the solution:
http://www.sysinternals.com/ntw2k/freeware/procexp.shtml

It really sounds strange, honestly... ;)

Icfu
This account is for sale
User avatar
Sheepdog
Power Member
Power Member
Posts: 5150
Joined: 2003-12-18, 21:44 UTC
Location: Berlin, Germany
Contact:

Post by *Sheepdog »

I found the reason. The root directory contained a file "beta1".

Apparently prevents it TC from parsing the correct path unless you use two pairs of quotation marks.


sheepdog
"A common mistake that people make when trying to design something
completely foolproof is to underestimate the ingenuity of complete fools."
Douglas Adams
User avatar
Clo
Moderator
Moderator
Posts: 5731
Joined: 2003-12-02, 19:01 UTC
Location: Bordeaux, France
Contact:

Type w/o ext.

Post by *Clo »

2Sheepdog
:) Hi Stefan !
¤ Files without extension cause bad jokes, specially when having the same name than a directory :P
- I created a file-type for that, with a visible icon, that could help, so files and dirs are distinguished one other.
¤ Something to add in the documents ;)

:mrgreen: V G
Claude
Clo
#31505 Traducteur Français de TC French translator Aide en Français Tutoriels Français English Tutorials
User avatar
Sheepdog
Power Member
Power Member
Posts: 5150
Joined: 2003-12-18, 21:44 UTC
Location: Berlin, Germany
Contact:

Re: Type w/o ext.

Post by *Sheepdog »

Clo wrote:¤ Files without extension cause bad jokes, specially when having the same name than a directory :P
You can't have a file with the same name as a directory in the same path. But I tested it and it happens too if there were no file beta1 but a directory.


sheepdog
"A common mistake that people make when trying to design something
completely foolproof is to underestimate the ingenuity of complete fools."
Douglas Adams
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50549
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

editor="E:\Beta1 6.5\AddOn\Textpad\Textpad.exe"
does not help.
Try this:
editor=""E:\Beta1 6.5\AddOn\Textpad\Textpad.exe""

Why? The loading of the string with the ini file functions will remove the outer double quotes, but TC still needs double quotes arount the name in the command line, otherwise Windows will look for a program called E:\Beta1 and pass the rest of it as parameters...
Author of Total Commander
https://www.ghisler.com
User avatar
Sheepdog
Power Member
Power Member
Posts: 5150
Joined: 2003-12-18, 21:44 UTC
Location: Berlin, Germany
Contact:

Post by *Sheepdog »

I had found this solution already and mentioned it in my first post. But mixed up some bbcode so it was not in blue like the others and you did not notice it.

Sorry for that, I corrected it now.

sheepdog
"A common mistake that people make when trying to design something
completely foolproof is to underestimate the ingenuity of complete fools."
Douglas Adams
Post Reply