Wrong values passed for %C, %C1, %C2, %c, %c1, %c2

The behaviour described in the bug report is either by design, or would be far too complex/time-consuming to be changed

Moderators: white, Hacker, petermad, Stefan2

raytc
Senior Member
Senior Member
Posts: 274
Joined: 2004-06-28, 11:03 UTC

Post by *raytc »

My question was just a reply to what Ghisler answered.
I don't see what's wrong with it.
I edited my reply to Ghisler a few hour later asking my question that's why I think he hasn't read it.
User avatar
Stefan2
Power Member
Power Member
Posts: 4133
Joined: 2007-09-13, 22:20 UTC
Location: Europa

Post by *Stefan2 »

raytc wrote:
I don't have a button associated with it. Where to open a button?

...

Any button will do, just one of the existing ones.


This will open the 'context sensitive' help page for the button settings and parameters.
That way you don't have to search the help yourself, TC will do that for you.


 
raytc
Senior Member
Senior Member
Posts: 274
Joined: 2004-06-28, 11:03 UTC

Post by *raytc »

Stefan2 wrote:
raytc wrote:
I don't have a button associated with it. Where to open a button?

...

Any button will do, just one of the existing ones.


This will open the 'context sensitive' help page for the button settings and parameters.
That way you don't have to search the help yourself, TC will do that for you.

 
Found it :) Never seen the parameter page.

However I still don't know the difference:

%C1 Like the first parameter of "Compare by content": First selected file, or file under cursor
%C2 Like the second parameter of "Compare by content": Second selected file, or first selected in target panel, or file with same name in target panel.

%C1 = %X%P%N
%C2 = %X%T%M
Is that correct?
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48028
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

No, you cannot replicate %C1 and %C2 with any of the other parameters. They depend on what is selected in the two panels.

As I wrote, it tries to replicate what "Compare by content" chooses:

1. Two or more files are selected in the source panel:
%C1 = first selected
%C2 = second selected

2. One file is selected in the source, and one file in the target panel
%C1 = left selected (not source!!!)
%C2 = right selected file

3. Nothing is selected in the source, and one file in the target panel
3a. left panel is the source:
%C1 = left file under the cursor
%C2 = right selected file
3b. right panel is the source:
%C1 = left selected file
%C2 = right file under the cursor

4. Nothing is selected in the source, and nothing is selected in the target
4a. left panel is the source:
%C1 = left file under the cursor
%C2 = file with same name as C1, but in the right directory
4b. right panel is the source:
%C1 = file with same name as C2, but in the left directory
%C2 = right file under the cursor
Author of Total Commander
https://www.ghisler.com
raytc
Senior Member
Senior Member
Posts: 274
Joined: 2004-06-28, 11:03 UTC

Post by *raytc »

Thank you very much!!

I finally made it.
I use %C1 and %C2 (compare content) together with Beyond Compare.
It never did really work.
Sometimes yes, sometimes no.
Today I've found out that I had to remove the double quotes around %C1 and %C2.

What I like about %C1 and %C2 is that I can use it selecting two files in the same panel.

Thanks for your great explication.
Wish you a nice day!
Post Reply