Solved [Tc 8.0 & 7.56a] Different behaviour of UseTrash
Moderators: Hacker, petermad, Stefan2, white
Solved [Tc 8.0 & 7.56a] Different behaviour of UseTrash
Settings:
VistaDelete=1
UseTrash=1
If I press F8 on a file, Windows aks if I want to move the file to the Recycle bin. This is expected behaviour.
If I press Shift+F8 on a file, TC aks if I want to delete the file and deletes it permanently. This is expected behaviour.
Settings:
VistaDelete=1
UseTrash=0
If I press F8 on a file, TC asks if I want to delete the file and deletes it permanently. This is expected behaviour.
If I press Shift+F8 on a file, Windows aks if I am sure whether I want to permanently delete the file. This is not expected behaviour - I expect the same behaviour no matter whether I use UseTrash=1 and press F8 or if I use UseTrash=0 and press Shift+F8. E.g I would expect Windows to ask if I want to move the file to the Recycle bin
---------------------------
In comparison to:
Settings:
VistaDelete=0
UseTrash=1
If I press F8 on a file TC asks if I want to delete the file and moves the file to the Recycle bin. This is expected behaviour.
If I press Shift+F8 on a file, TC aks if I want to delete the file and deletes it permanently. This is expected behaviour.
Settings:
VistaDelete=0
UseTrash=0
If I press F8 on a file, TC asks if I want to delete the file and deletes it permanently. This is expected behaviour.
If I press Shift+F8 on a file TC asks if I want to delete the file and moves the file to the Recycle bin. This is expected behaviour.
I think it is a bug that UseTrash=0 and pressing Shift+F8 doesn't lead to the same result whether or not VistaDelete is set to 0 or 1.
VistaDelete=1
UseTrash=1
If I press F8 on a file, Windows aks if I want to move the file to the Recycle bin. This is expected behaviour.
If I press Shift+F8 on a file, TC aks if I want to delete the file and deletes it permanently. This is expected behaviour.
Settings:
VistaDelete=1
UseTrash=0
If I press F8 on a file, TC asks if I want to delete the file and deletes it permanently. This is expected behaviour.
If I press Shift+F8 on a file, Windows aks if I am sure whether I want to permanently delete the file. This is not expected behaviour - I expect the same behaviour no matter whether I use UseTrash=1 and press F8 or if I use UseTrash=0 and press Shift+F8. E.g I would expect Windows to ask if I want to move the file to the Recycle bin
---------------------------
In comparison to:
Settings:
VistaDelete=0
UseTrash=1
If I press F8 on a file TC asks if I want to delete the file and moves the file to the Recycle bin. This is expected behaviour.
If I press Shift+F8 on a file, TC aks if I want to delete the file and deletes it permanently. This is expected behaviour.
Settings:
VistaDelete=0
UseTrash=0
If I press F8 on a file, TC asks if I want to delete the file and deletes it permanently. This is expected behaviour.
If I press Shift+F8 on a file TC asks if I want to delete the file and moves the file to the Recycle bin. This is expected behaviour.
I think it is a bug that UseTrash=0 and pressing Shift+F8 doesn't lead to the same result whether or not VistaDelete is set to 0 or 1.
Last edited by petermad on 2021-05-30, 17:08 UTC, edited 3 times 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
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
- sqa_wizard
- Power Member
- Posts: 3893
- Joined: 2003-02-06, 11:41 UTC
- Location: Germany
2sqa_wizard
It was because of Karlchens answer that I looked into it.
But my report doesn't concern quite the same - it concerns the effect of the setting of UseTrash (or "Configuration" -> "Options..." -> "Copy/Delete" -> "General Copy+Delete options" -> "F8/Del deletes to recycle bin (Shift=directly)".
With VistaDelete=0 and in all previous TC versions before VistaDelete, disabeling this setting made Shift+F8 reverse the setting and delete to recycle bin anyway.
With VistaDelete=1 or Vistadelete absent in TC 8.0b7 disabeling the setting (UseTrash=0) does no longer make Shift+F8 delete to recycle bin - it results in Windows - not TC - deleting the file permanently.
My complaint is that using Shift+F8 does not result in deleting to recycle bin, when UseTrash=0 if VistaDelete=1.
Personally I don't care - I have usually disabled recycle bin on system level (only enabled it temporarily for testing this). But some people might be surprised when they use Shift+F8 (and have UseTrash=0) and then cannot find the file in the recycle bin later.
I have now edited my first post to try to make it even clearer what it is about...
It was because of Karlchens answer that I looked into it.
But my report doesn't concern quite the same - it concerns the effect of the setting of UseTrash (or "Configuration" -> "Options..." -> "Copy/Delete" -> "General Copy+Delete options" -> "F8/Del deletes to recycle bin (Shift=directly)".
With VistaDelete=0 and in all previous TC versions before VistaDelete, disabeling this setting made Shift+F8 reverse the setting and delete to recycle bin anyway.
With VistaDelete=1 or Vistadelete absent in TC 8.0b7 disabeling the setting (UseTrash=0) does no longer make Shift+F8 delete to recycle bin - it results in Windows - not TC - deleting the file permanently.
My complaint is that using Shift+F8 does not result in deleting to recycle bin, when UseTrash=0 if VistaDelete=1.
Personally I don't care - I have usually disabled recycle bin on system level (only enabled it temporarily for testing this). But some people might be surprised when they use Shift+F8 (and have UseTrash=0) and then cannot find the file in the recycle bin later.
I have now edited my first post to try to make it even clearer what it is about...
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
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
- sqa_wizard
- Power Member
- Posts: 3893
- Joined: 2003-02-06, 11:41 UTC
- Location: Germany
Well, I mainly refer to the statement:
Windows takes control over deletion process!
Hence: "UseTrash=" option is not considered anymore, Windows recycle bin settings are valid now.
My conclusion is:karlchen wrote:I.e with VistaDelete=1 (==new default behaviour on Vista and above), Windows is responsible for the different layouts of the confirmation dialogues, not Total Commander.
Windows takes control over deletion process!
Hence: "UseTrash=" option is not considered anymore, Windows recycle bin settings are valid now.
#5767 Personal license
I totally disagree with that.
IMHO the UseTrash setting tells whether the user wants f8/Del to delete the file or to move it to recycle bin (and reverse the choice when using the Shift modifier key). Whether or not the desired action has to be carried out by TC or by the VistaDelete method should be of no relevance to the UseTrash setting.
And as I wrote, I had set up my Windows to use the recycle bin - but still Windows will delete permanently when I press Shift+F8 and VistaDelete=1 and UseTrash=0 but moves to recycle bin when pressing F8 and UseTrash=1 - so that shows that the UseTrash setting does affect what Windows does - it just results in the wrong action from Windows when UseTrash=0.
What TC seems to do now, is passing on the shift-key status to Windows when requesting the deletion, and since Shift+Del in Explorer results in permanently deleting, this also happens in TC, despite the setting of UseTrash.
IMHO the UseTrash setting tells whether the user wants f8/Del to delete the file or to move it to recycle bin (and reverse the choice when using the Shift modifier key). Whether or not the desired action has to be carried out by TC or by the VistaDelete method should be of no relevance to the UseTrash setting.
This refers to the fact that of course it is Windows that shows the dialogue when it is Windows that is going to carry it out.Windows is responsible for the different layouts of the confirmation dialogues,
And as I wrote, I had set up my Windows to use the recycle bin - but still Windows will delete permanently when I press Shift+F8 and VistaDelete=1 and UseTrash=0 but moves to recycle bin when pressing F8 and UseTrash=1 - so that shows that the UseTrash setting does affect what Windows does - it just results in the wrong action from Windows when UseTrash=0.
What TC seems to do now, is passing on the shift-key status to Windows when requesting the deletion, and since Shift+Del in Explorer results in permanently deleting, this also happens in TC, despite the setting of UseTrash.
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
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
Petermad is right:
I have not taken into account and have not tested what happens if you make T.C. by pass the recycle bin when deleting, i.e UseTrash=0.
Neglecting to take this T.C. parameter into account is due to the fact that I have never understood why it should make sense to have the Windows recycle bin enabled, but tell T.C. to bypass it as a rule. As a consequence I have never changed the T.C. default: UseTrash=1.
Moreover let me make clear that only with VistaDelete=1 Windows will ask whether you wish to move object(s) to the recycle bin, not T.C., provided you tell T.C. to delete to the recycle bin.
(Default = UseTrash=1, by pressing <DEL> or <F8>)
If you tell T.C. to delete bypassing the recycle bin, irrespective of VistaDelete, it is always T.C. which asks for confirmation.
(Default = UseTrash=1, by pressing <Shift><DEL> or <Shift><F8>)
Yet I had said so in the other thread, but without paying attention to the fact that you can revert the meaning of <DEL> / <F8> and <Shift><DEL> / <Shift><F8>.
Karl
I have not taken into account and have not tested what happens if you make T.C. by pass the recycle bin when deleting, i.e UseTrash=0.
Neglecting to take this T.C. parameter into account is due to the fact that I have never understood why it should make sense to have the Windows recycle bin enabled, but tell T.C. to bypass it as a rule. As a consequence I have never changed the T.C. default: UseTrash=1.
Moreover let me make clear that only with VistaDelete=1 Windows will ask whether you wish to move object(s) to the recycle bin, not T.C., provided you tell T.C. to delete to the recycle bin.
(Default = UseTrash=1, by pressing <DEL> or <F8>)
If you tell T.C. to delete bypassing the recycle bin, irrespective of VistaDelete, it is always T.C. which asks for confirmation.
(Default = UseTrash=1, by pressing <Shift><DEL> or <Shift><F8>)
Yet I had said so in the other thread, but without paying attention to the fact that you can revert the meaning of <DEL> / <F8> and <Shift><DEL> / <Shift><F8>.
Karl
It was always a mystery for me why:
Wouldn't
Regards
Holger
did not what it said, but only inverts the meaning of the modifier <Shift> while deleting...UseTrash=1 Use Recycle Bin if available and enabled
Wouldn't
be a more logical interpretation?"UseTrash=0 Do not use Recycle Bin even if available and enabled"
Regards
Holger
Hello, HolgerK.
As far as I understand, "UseTrash" just tells T.C. what its own preferred delete behaviour should be:
Any potential "UseTrash" confusion exists independently of the parameter "VistaDelete".
But the interaction between "UseTrash" and "VistaDelete" is not totally unlikely to increase this confusion.
What makes things even more complicated is that the parameters "UseTrash" and "VistaDelete" have got no influence on or control over the Windows settings "Use recycle bin" and "Ask for confirmation before deleting".
But the Windows recycle bin configuration will have influence on whether
+ T.C. can delete to the recycle bin at all even if told to do so.
+ the user will be asked to confirm "delete to trash" if VistaDelete is on, but the Windows recycle bin confirmation is off.
Cheers,
Karl
As far as I understand, "UseTrash" just tells T.C. what its own preferred delete behaviour should be:
- UseTrash=1 (default) tells T.C. to try to delete to the Windows Recycle Bin. This does not switch the Windows Recycle Bin on in case it has been disabled.
The default keys to trigger deletion are <DEL> / <F8>. They will trigger the configured T.C. delete method, which in this case is "move to recylce bin".
On a case by case basis you can revert the current delete method to the opposite by pressing <Shift><DEL> / <Shift><F8>. - UseTrash=0 tells T.C. to try to delete by bypassing the Windows Recycle Bin. This does not switch the Windows Recycle Bin off in case it has is enabled.
The default keys to trigger deletion are <DEL> / <F8>. They will trigger the configured T.C. delete method, which in this case is "delete bypassing the recycle bin".
On a case by case basis you can revert the current delete method to the opposite by pressing <Shift><DEL> / <Shift><F8>.
- delete to recycle bin (default) vs delete bypassing recycle bin.
- The configured preferred method is invoked by pressing <Del> / <F8>.
- On a case by case basis, you use the other delete method by adding the modifier key <shift>.
- The problem really is that without checking the T.C. configuration first, you cannot know which delete method will be used by <DEL>/<F8> and which one by <Shift><Del> / <Shift><F8>.
- It is much like a light switch where you never know whether the on/off positions have been swapped or not.
Any potential "UseTrash" confusion exists independently of the parameter "VistaDelete".
But the interaction between "UseTrash" and "VistaDelete" is not totally unlikely to increase this confusion.
What makes things even more complicated is that the parameters "UseTrash" and "VistaDelete" have got no influence on or control over the Windows settings "Use recycle bin" and "Ask for confirmation before deleting".
But the Windows recycle bin configuration will have influence on whether
+ T.C. can delete to the recycle bin at all even if told to do so.
+ the user will be asked to confirm "delete to trash" if VistaDelete is on, but the Windows recycle bin confirmation is off.
Cheers,
Karl
I know how "UseTrash" works.
My comment about it, was that the binary interpretation is more like:
Use the recycle.bin or use is not. (in any case!)
A name like TCsInternalDeleteBehaviorConsideringTheStateOfThe ModifierKeyShift would match the actual behavior better.
Anyway, also if i always bypass recylce bin by pressing <Shift>, i have never changed this key different from its default, because i want a consistent handling of <Del> and <Shift+Del> in any place (also inside file dialogs).
"Win95Delete=1" (Use Explorer delete method) disables any interpretation of "UseTrash" (just to add some more confusion
).
Regards
Holger
My comment about it, was that the binary interpretation is more like:
Use the recycle.bin or use is not. (in any case!)
A name like TCsInternalDeleteBehaviorConsideringTheStateOfThe ModifierKeyShift would match the actual behavior better.
Anyway, also if i always bypass recylce bin by pressing <Shift>, i have never changed this key different from its default, because i want a consistent handling of <Del> and <Shift+Del> in any place (also inside file dialogs).
There is already a dependency from another existing key:Any potential "UseTrash" confusion exists independently of the parameter "VistaDelete".
But the interaction between "UseTrash" and "VistaDelete" is not totally unlikely to increase this confusion.
"Win95Delete=1" (Use Explorer delete method) disables any interpretation of "UseTrash" (just to add some more confusion

Regards
Holger
- ghisler(Author)
- Site Admin
- Posts: 50479
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Confirmed, UseTrash=0 should use the trash with Shift+F6. I will fix it.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Confirmed fixed in TC 8.0b8 
UseTrash now does what it is expected to, also when VistaDelete=1

UseTrash now does what it is expected to, also when VistaDelete=1
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
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
- ghisler(Author)
- Site Admin
- Posts: 50479
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact: