Close All Tabs, one click, both panels including locked ones

English support forum

Moderators: sheep, Hacker, Stefan2, white

Post Reply
Spiderkeys
Junior Member
Junior Member
Posts: 51
Joined: 2015-04-07, 10:02 UTC

Close All Tabs, one click, both panels including locked ones

Post by *Spiderkeys »

I'm wondering which would be the best way to be able to close all tabs with one click such as a custom button, which will close both panels including locked ones and without any confirmations.

I know there is already a build in command of "Close All Tabs", but it only does the selected panel.

I thought of a batch file to modify ini files, and then a restart but I think surely there's a easier way.
User avatar
KC_
Junior Member
Junior Member
Posts: 93
Joined: 2012-03-07, 01:39 UTC

Post by *KC_ »

you can use OPENTABS to open a saved tab file

Code: Select all

cmd=OPENTABS "%COMMANDER_PATH%\Tabs\closeall.tab"
my closeall.tab

Code: Select all

[activetabs]
0_path=C:\
0_options=1|0|0|0|0|0|0
activetab=0
[inactivetabs]
0_path=C:\
0_options=1|0|0|0|0|0|0
activetab=0
# 251045
Total Commander 10.5 64bit
Spiderkeys
Junior Member
Junior Member
Posts: 51
Joined: 2015-04-07, 10:02 UTC

Post by *Spiderkeys »

Ahh! I Didn't think, just make a new button up with OPENTABS, set up two single common visited folders in both panels, and saved it as a tab.

That is so much better than the CLOSEALLTABS command, fixed in less than a minute!

EDIT: I've been spending weeks with batch files and autohotkey scripts opening up multiple tabs for whatever project im undertaking

which repeated lines of TOTALCMD64.EXE /O /T /R=(DIRECTORY)'s

Obviously bad scripting, I wonder if you can just open a saved .tab file from a single entry in a batch or from the command prompt.
User avatar
petermad
Power Member
Power Member
Posts: 9848
Joined: 2003-02-05, 20:24 UTC
Location: Valsted, Denmark
Contact:

Post by *petermad »

May I suggest to change the closeall.tab file to:

Code: Select all

[activetabs]
0_path=.
0_options=1|0|0|0|0|0|0
activetab=0
[inactivetabs]
0_path=.
0_options=1|0|0|0|0|0|0
activetab=0
Then the currently displayed folders will also be the ones that are displayed after the tabs are closed.
License #524 (1994)
Danish Total Commander Translator
TC 9.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (2004) 64bit, 'Everything' 1.4.1.988 (x64)
TC 3.10 on Android 6.0
Get:
Extended TC Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Post Reply