Problem with filne name encoding

English support forum

Moderators: Hacker, petermad, Stefan2, white

MarekCzerski
Junior Member
Junior Member
Posts: 27
Joined: 2015-01-22, 01:18 UTC

Re: Problem with filne name encoding

Post by *MarekCzerski »

Gral wrote: 2022-02-21, 20:25 UTC There is probably no more elegant solution than the one I described earlier - a button that sends a list of files to Irfan

The possibilities of TC are (almost) unlimited.
However, to advise you, we need to know what you want to achieve.
I thought after your earlier post that you have solved all the problems. So what do you really want to do?
It seems that one of my messages had not gone through and that’s why my later message seemed quite weird. When I found that my message is missing I posted another version a few minutes ago and I hope it will explain why my joy occurreed somewhat shortlived and premature.

You’ll find my explanations in a message in which I discuss the problem which arises form the fact that the procedure you advised (and I am grateful for) has certain limitation as regards saving full paths of selected files to be save and read by IrfanView.

I hope that I have cleared the misunderstanding concerning what I really want.
MarekCzerski
Junior Member
Junior Member
Posts: 27
Joined: 2015-01-22, 01:18 UTC

Re: Problem with filne name encoding

Post by *MarekCzerski »

Gral wrote: 2022-02-21, 20:25 UTC There is probably no more elegant solution than the one I described earlier - a button that sends a list of files to Irfan

The possibilities of TC are (almost) unlimited.
However, to advise you, we need to know what you want to achieve.
I thought after your earlier post that you have solved all the problems. So what do you really want to do?
It seems that one of my messages had not gone through and that’s why my later message seemed quite weird. When I found that my message is missing I posted another version a few minutes ago and I hope it will explain why my joy occurreed somewhat shortlived and premature.

You’ll find my explanations in a message in which I discuss the problem which arises form the fact that the procedure you advised (and I am grateful for) has certain limitation as regards saving full paths of selected files to be save and read by IrfanView.

I hope that I have cleared the misunderstanding concerning what I really want.
MarekCzerski
Junior Member
Junior Member
Posts: 27
Joined: 2015-01-22, 01:18 UTC

Re: Problem with filne name encoding

Post by *MarekCzerski »

Sorry for the mess in the thread. It seems that my FF behaves badly and unpredictably. I do appologize for all inconvenience.
Marek



It seems that one of my messages has not come through.
I reported a problem with the feature of "Save Selection to File".

It occurred that when I select files from one and the same folder, the filenames are saved into a txt file withouth their full paths. And further, if the txt file with the filelist is saved in the same folder in which the selected files are kept, then IrfanView is capable to use the selection as file paths to the txt file are added by IrfanView automatically to each filename as soon as the txt file is read by IrfanView. All the filepaths added in this way are the same as they are just the path to the txt file as well as to the selected files. However, if I save the txt file with a filelist to a folder other than that in the selected files are kept, then IrfanView is hopeless as it cannot find files because filepaths added to them by IrfanViewa are the filepath of the txt file rather than of each single file selected.

It is interesting, however, that when I select files from a search result showing files in different folders, the "Save Selection to File" works properly and saves filenames with their various full file paths.

My question: is there a TC function that ALLWAYS allows to save selected files with their full paths. I tried a number of functions offered in the option of Misc > Redefine hotkeys (as I find this feature really handy), but to no avail. Hence, I have no choice, but to ask your kind advice.
User avatar
Gral
Power Member
Power Member
Posts: 1609
Joined: 2005-01-26, 15:12 UTC

Re: Problem with filne name encoding

Post by *Gral »

Easiest way - select files and press such a button.
(to create button copy code, right click on empty space on buttonbar and choose "Paste"

Code: Select all

TOTALCMD#BAR#DATA
NOTEPAD.EXE
%UL
NOTEPAD.EXE



-1
Now, just save file with new name.
MarekCzerski
Junior Member
Junior Member
Posts: 27
Joined: 2015-01-22, 01:18 UTC

Re: Problem with filne name encoding

Post by *MarekCzerski »

Thanks. And again you have appeared as a great expert. One question: Is there a programmatic way to program the button or otherwise, so that the result is not presented in the format of a tmp file, but readily saved under one and the same disc address and name?
User avatar
Gral
Power Member
Power Member
Posts: 1609
Joined: 2005-01-26, 15:12 UTC

Re: Problem with filne name encoding

Post by *Gral »

Old good "DOS" command - COPY, e.g. such a button:

Code: Select all

TOTALCMD#BAR#DATA
CMD.EXE /C COPY
%UL C:\TOTALCMD\FILELIST.TXT
wcmicons.dll,62


0
-1
You can also create this as a user command, just add code below to USERCMD.INI

Code: Select all

[em_copyfilelist]
button=wcmicons.dll,62
cmd=CMD.EXE /C COPY
param=%UL C:\TOTALCMD\FILELIST.TXT
This is example, change "C:\TOTALCMD\FILELIST.TXT" to any (writeable) path and name you wish.

After create user command you can define hotkey for it.
MarekCzerski
Junior Member
Junior Member
Posts: 27
Joined: 2015-01-22, 01:18 UTC

Re: Problem with filne name encoding

Post by *MarekCzerski »

Oh, my Lord, good old DOS commands in use? I am about to get sentimental... :)

It is really impressive and amazing how helpful you appear to be. You seem to have made me speechless – may all people be that praiseworthy as you are. Everything works fine and all problems have been solved at last.

I feel confused that I have taken so much of your time. Is there a guidebook or other manual on TC programming? I have achieved quite a good level of competence in C++ and VB6, so I hope I would manage to learn TC arcana and – which is most important – I would not have to bother you and other fellows with shamefuly simple quesitons, which I think my problems eventually have occurred.

Cheers!
User avatar
Gral
Power Member
Power Member
Posts: 1609
Joined: 2005-01-26, 15:12 UTC

Re: Problem with filne name encoding

Post by *Gral »

Thank you for the kind words. I help as much as I can.
There is no single place where all knowledge about TC is collected.
Surely the help file and this forum are a good starting point.
Some useful information can also be found on TC WIKI.
You can always ask here, usually there will be someone who knows the solution, I'm definitely not the best TC expert.
User avatar
Stefan2
Power Member
Power Member
Posts: 4281
Joined: 2007-09-13, 22:20 UTC
Location: Europa

Re: Problem with filne name encoding

Post by *Stefan2 »

MarekCzerski wrote: 2022-02-22, 00:46 UTC Is there a guidebook or other manual on TC programming?

We have tried to collect some links and info on this page > https://ghisler.ch/board/viewtopic.php?f=3&t=52425

Maybe read about WM_USER and sendmessage and create some need tools in C++ and VB6 :D





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

Re: Problem with filne name encoding

Post by *petermad »

2MarekCzerski
My question: is there a TC function that ALLWAYS allows to save selected files with their full paths. I tried a number of functions offered in the option of Misc > Redefine hotkeys (as I find this feature really handy), but to no avail. Hence, I have no choice, but to ask your kind advice.
If you install my Extended Menus (see signature) - there is a whole submenu dedicated to copying filenames . see: https://madsenworld.dk/tcmd/copynamesmenu2.png

menu items with a * at the end uses DOS.

Maybe something there could help you...
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
Post Reply