Quick way to search and replace a known file?

English support forum

Moderators: Hacker, petermad, Stefan2, white

Post Reply
pingmustard
Junior Member
Junior Member
Posts: 12
Joined: 2008-01-31, 18:59 UTC

Quick way to search and replace a known file?

Post by *pingmustard »

We have duplicate copies of a file in our deployed system. From time to time, a bug is found and we need to get all instance of the file replaced with a new version.

Is there a quick way to do this? In the past, I've just searched for the specific DLL, and then just resorted to manual copy/paste. However, when there's ~30 instance of the dll out there, it's a bit of a pain to do manually.
User avatar
petermad
Power Member
Power Member
Posts: 16141
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

You can do the following:

1. Do a search for the specific DLL file.
2: Feed the search result to listbox.
3. Mark all the files in listbox.
4. From the oposite panel choose the new DLL file and press F5.
5. In the copy dialog check the "Copy to all selected folders/links in the target panel"
6. Press OK and accept to "Overwrite all" in the warning dialog.
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
User avatar
MVV
Power Member
Power Member
Posts: 8711
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

AFAIK it only works if folders or LNKs are selected, it has no effect on selected files.
User avatar
Horst.Epp
Power Member
Power Member
Posts: 7025
Joined: 2003-02-06, 17:36 UTC
Location: Germany

Post by *Horst.Epp »

MVV wrote:AFAIK it only works if folders or LNKs are selected, it has no effect on selected files.
The options text is wrong, it works also with selected files.
Tested with TC 8.51b3 x64
User avatar
petermad
Power Member
Power Member
Posts: 16141
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

Tested with TC 8.51b3 x64
So did I before I wrote my previous post. ;-)
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
User avatar
MVV
Power Member
Power Member
Posts: 8711
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

I tried it again and it doesn't replace any selected in target panel files. Yesterday I've tried with regular panel, now I tried it with search results panel. None of selected files in a target panel were modified, and no warnings was shown, TC simply copes source file into folders where target files located. In this particular case with same file names it may work but it won't if filenames are different.
User avatar
Horst.Epp
Power Member
Power Member
Posts: 7025
Joined: 2003-02-06, 17:36 UTC
Location: Germany

Post by *Horst.Epp »

MVV wrote:I tried it again and it doesn't replace any selected in target panel files. Yesterday I've tried with regular panel, now I tried it with search results panel. None of selected files in a target panel were modified, and no warnings was shown, TC simply copes source file into folders where target files located. In this particular case with same file names it may work but it won't if filenames are different.
The topic is to replace identical named files !
Of course it doesn't override other files in the target dirs.
But how should there other named files if the search was for a specific file name. :D
User avatar
petermad
Power Member
Power Member
Posts: 16141
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

2MVV
I tried it again and it doesn't replace any selected in target panel files.
Try again - it seems to me that you forget to check the option: "Copy to all selected folders/links in the target panel" in the bottom of the Copy dialog...?

It works both to a Feed-to-lisbox panel and to a Branch view panel.
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
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50923
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

I would create LNK files to the directories where these files are - you need to do this only once, then you can use "Copy to all selected folders/links in the target panel" every time. I use this myself to copy new translations to 4 different places.
Author of Total Commander
https://www.ghisler.com
User avatar
white
Power Member
Power Member
Posts: 6013
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Post by *white »

ghisler(Author) wrote:I would create LNK files to the directories where these files are - you need to do this only once, then you can use "Copy to all selected folders/links in the target panel" every time. I use this myself to copy new translations to 4 different places.
Instead of making additional shortcuts it would be far better to use "download lists" for that. People have asked for these Total Commander batch files regularly. Can you please make the use of this more user friendly. For example make it so we can execute these "download lists" by double clicking a download list or implement an internal command with parameter so we can use a button etc. to launch it.
Last edited by white on 2022-03-22, 21:26 UTC, edited 1 time in total.
Reason: fixed link
Post Reply