"copy" command on button bar to add a zip file wit

English support forum

Moderators: white, Hacker, petermad, Stefan2

Post Reply
sorcar
Member
Member
Posts: 100
Joined: 2005-04-12, 17:45 UTC
Location: U.S.

"copy" command on button bar to add a zip file wit

Post by *sorcar »

Can anyone show how to put on a button bar the following two selected files in the same pane:

Code: Select all

First file.jpg
Second file.zip
so that the command executed is:

Code: Select all

copy /b "First file.jpg" + "Second file.zip"
What about if the files selected are in different panes?

Thanks in advance.

Last edited by sorcar on 2017-05-21, 00:21 UTC, edited 2 times in total.
User avatar
Ovg
Power Member
Power Member
Posts: 756
Joined: 2014-01-06, 16:26 UTC

Post by *Ovg »

2sorcar
For TC 9.0:

1. In The same pane
First selected file - %C1
Second selected file - %C2

2. Different Panes
Selected in Left pane - %X%P%S
Selected in Right pane - %T%R
It's impossible to lead us astray for we don't care even to choose the way.
#259941, TC 11.01 x64, Windows 7 SP1 x64
User avatar
Dalai
Power Member
Power Member
Posts: 9392
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Post by *Dalai »

Well, you can append files to another with TC: copy a file (F5), type the name of an existing file and select "Append" in the overwrite dialog, and confirm the action. This also works with a greater number of files (although it's a bit of a hassle to handle all confirmations) and regardless of whether the files are in the same panel or not.

Regards
Dalai
#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
Hacker
Moderator
Moderator
Posts: 13067
Joined: 2003-02-06, 14:56 UTC
Location: Bratislava, Slovakia

Post by *Hacker »

Dalai,
select "Append" in the overwrite dialog
IIRC this does not work with the default copy mode, only with TC's own copy mode.

Roman
Mal angenommen, du drückst Strg+F, wählst die FTP-Verbindung (mit gespeichertem Passwort), klickst aber nicht auf Verbinden, sondern fällst tot um.
User avatar
Dalai
Power Member
Power Member
Posts: 9392
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Post by *Dalai »

2Hacker
I just tested it and it works without a hitch, regardless of the copy method.

Regards
Dalai
#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
Hacker
Moderator
Moderator
Posts: 13067
Joined: 2003-02-06, 14:56 UTC
Location: Bratislava, Slovakia

Post by *Hacker »

Dalai,
Funny, perhaps it was implemented meanwhile?
Missing append button

Roman
Mal angenommen, du drückst Strg+F, wählst die FTP-Verbindung (mit gespeichertem Passwort), klickst aber nicht auf Verbinden, sondern fällst tot um.
User avatar
Dalai
Power Member
Power Member
Posts: 9392
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Post by *Dalai »

2Hacker
Looks like it:
history.txt wrote:01.12.08 Release Total Commander 7.50 Beta 1
[...]
12.11.08 Added: Offer "Append" option also when using compatibility mode, by using internal copy method when "Append" is chosen
Regards
Dalai
#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
Hacker
Moderator
Moderator
Posts: 13067
Joined: 2003-02-06, 14:56 UTC
Location: Bratislava, Slovakia

Post by *Hacker »

Dalai,
Thanks. ;)

Roman
Mal angenommen, du drückst Strg+F, wählst die FTP-Verbindung (mit gespeichertem Passwort), klickst aber nicht auf Verbinden, sondern fällst tot um.
sorcar
Member
Member
Posts: 100
Joined: 2005-04-12, 17:45 UTC
Location: U.S.

I want to add a .jpg file and a .zip file

Post by *sorcar »

Thanks, Ovg. I did this:

Command: %comspec% /c copy /b
Parameters: %C1+%C2

I have found this working whether the files are in the same or in different panes. Only, I needed to return the cursor to the source pane.

I should perhaps clarify my intent in case someone finds it useful.

I have a slightly different set of files than in the .txt file example I gave above. My pair of files are "Picture of Robert Frost.jpg" and "Poems of Robert Frost.zip". [There are many more such]. I wanted to add them by running:

Code: Select all

copy /b "Picture of Robert Frost.jpg" + "Poems of Robert Frost.zip"
The .jpg file and the .zip file may in the same or different panes.

For anybody who might wonder why, this adds the .zip file to the .jpg file, which can be viewed by pressing Control+PgDn on the .jpg file. I can thus archive a scan of the whole Robert Frost book (in zip format) inside his image! It is a stenographic technique, but for my purpose it is smart archiving.

I added this long, somewhat off-topic explanation, hoping that some rare ones may find this unorthodox use worthwhile.

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

Post by *petermad »

2Ovg
1. In The same pane
First selected file - %C1
Second selected file - %C2

2. Different Panes
Selected in Left pane - %X%P%S
Selected in Right pane - %T%R
You can till use %C1 and %C2 also for files in different panels, but notice that if the focus is on the right panel then %C1 will still be the file in the left panel and %C2 the one in the right panel.
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
petermad
Power Member
Power Member
Posts: 14808
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

2sorcar
to the .jpg file, which can be viewed by pressing Control+PgDn on the .jpg file.
This seems to only work if you have Total7zip installed as a packer plugin and if it installed before the Imagine packer plugin (if you have both).
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
sorcar
Member
Member
Posts: 100
Joined: 2005-04-12, 17:45 UTC
Location: U.S.

You gave me a lifesaving tip

Post by *sorcar »

2petermad
This seems to only work if you have Total7zip installed as a packer plugin and if it installed before the Imagine packer plugin (if you have both).
How in the world did you find out? I thought, presumptuously, that the internal un-RAR function of TC does it (as WinRAR can open such jpg files with zip files). I have noted though that changing author.jpg to author.jpg.zip can be opened without any plugin.

It is a lifesaving tip to me when I am scanning my personal library of printed books and putting them behind images of their authors. Thanks, Petermad.
Post Reply