Bug with filenames with the % character

English support forum

Moderators: Hacker, petermad, Stefan2, white

Post Reply
bzi99
Junior Member
Junior Member
Posts: 4
Joined: 2003-12-28, 11:44 UTC

Bug with filenames with the % character

Post by *bzi99 »

Hi!

I've found TC 6.01 doesn't know how to deal with files with the % character in them, stopping the user from moving, copying or renaming the file.
Same examples of filenames: slb%252003.txt, oke%20doke, etc.

B Z
User avatar
Lefteous
Power Member
Power Member
Posts: 9536
Joined: 2003-02-09, 01:18 UTC
Location: Germany
Contact:

Post by *Lefteous »

2bzi99

I cannot reproduce this behavior. It works fine for me.
bzi99
Junior Member
Junior Member
Posts: 4
Joined: 2003-12-28, 11:44 UTC

Post by *bzi99 »

Lefteous wrote:2bzi99
I cannot reproduce this behavior. It works fine for me.
Checked again. Still doesn't work for me :-| Maybe the problem it's related to the codepage used by XP? (Note: I don't have this problem in the DOS command line)

B Z
User avatar
djk
Power Member
Power Member
Posts: 1651
Joined: 2003-03-17, 11:33 UTC
Location: Poland
Contact:

Post by *djk »

I also has no problem (on WnXp Pro PL)
DJK
Totally addicted to Total Commander
totalcmd.pl
en.totalcmd.pl
User avatar
Horst.Epp
Power Member
Power Member
Posts: 6968
Joined: 2003-02-06, 17:36 UTC
Location: Germany

Post by *Horst.Epp »

No problem in WinXp Home SP1 German
using TC 6.01
User avatar
petermad
Power Member
Power Member
Posts: 16021
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

No problem in Win98Se Danish

:P
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
bzi99
Junior Member
Junior Member
Posts: 4
Joined: 2003-12-28, 11:44 UTC

Re: Bug with filenames with the % character

Post by *bzi99 »

Ops... forgot to tell: the problem appears only when in command line. For instance, typing "move oke%20doke .." doesn't work but F6 will.
(I'm using XP Home SP1)

B Z
User avatar
petermad
Power Member
Power Member
Posts: 16021
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

I tried it out (under Win98SE):

The commands DEL, COPY, REN and MOVE all worked from the command line with filenames like your examples (slb%252003.txt).

But :!: Sometimes the panels are not updated when using DEL, COPY and REN - you have to press F2 or Ctrl-R to make TC update the panels.

That only happens when when the setting of the screen is set to "window" (in contrary to "full screen") in the file COMMAND.PIF. I can't find any pattern for whether or not TC choses to update the file panels after using REN, DEL or COPY.

Using MOVE is different, because MOVE is not an internal command (internal to command.com or cmd.com) - MOVE is an executable program (MOVE.EXE).

I don't have any panel updating problems in TC using MOVE - and it doesn't matter whether I use "full screen" or "window" in the settings in MOVE.PIF
Last edited by petermad on 2003-12-31, 16:06 UTC, edited 1 time in total.
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50475
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

TC uses environment variable substitution on the command line. % may be interpreted by Windows as the start of an environment variable.
Author of Total Commander
https://www.ghisler.com
User avatar
CopyCats
Member
Member
Posts: 195
Joined: 2003-02-05, 13:09 UTC
Location: Netherlands
Contact:

Post by *CopyCats »

ghisler(Author) wrote:TC uses environment variable substitution on the command line. % may be interpreted by Windows as the start of an environment variable.
In that case, wouldn't it help if he puts the filename between quotes? Like this: copy "slb%252003.txt" <target>
#5050 :: Everyone who believes in telekinesis, raise my hand!
jb
Senior Member
Senior Member
Posts: 412
Joined: 2003-02-09, 22:56 UTC
Location: Switzerland

Post by *jb »

CopyCats wrote:
ghisler(Author) wrote:TC uses environment variable substitution on the command line. % may be interpreted by Windows as the start of an environment variable.
In that case, wouldn't it help if he puts the filename between quotes? Like this: copy "slb%252003.txt" <target>
No, it would not help. Windows substitutes environment variables also in quotes. This can be verified easily by the following commands:

Code: Select all

pushd "%ProgramFiles%"
popd
pushd %ProgramFiles%
popd
bzi99
Junior Member
Junior Member
Posts: 4
Joined: 2003-12-28, 11:44 UTC

Post by *bzi99 »

CopyCats wrote:In that case, wouldn't it help if he puts the filename between quotes? Like this: copy "slb%252003.txt" <target>
Note that in the XP command prompt, that command *works* (even without quotes), only in TC you have to put escape the % character (slb%%25...).

B Z
Post Reply