START with defined folders: how to go back to START again?

English support forum

Moderators: white, Hacker, petermad, Stefan2

Post Reply
Fotis_Greece
Junior Member
Junior Member
Posts: 13
Joined: 2004-03-06, 14:07 UTC

START with defined folders: how to go back to START again?

Post by *Fotis_Greece »

Go to "start" position, is it possible?

Hello dear friends,
I am using TC for quite a long now. I do have one question though.
I have configured TC to start with panels at selected certain folders. After doing my job and going to various other folders, is it possible to go back to start position with one click?
I currently exit and restart TC to achieve this.
Thank you
User avatar
sqa_wizard
Power Member
Power Member
Posts: 3862
Joined: 2003-02-06, 11:41 UTC
Location: Germany

Post by *sqa_wizard »

From the context menu of a tab select "Save tabs on both sides to file"
After this you have to create button with "OPENTABS <filename>"
With a click on this button you get back to start position.
#5767 Personal license
User avatar
Stefan2
Power Member
Power Member
Posts: 4157
Joined: 2007-09-13, 22:20 UTC
Location: Europa

DOS: Restart TC, Kill and start launch TC

Post by *Stefan2 »

Fotis_Greece wrote:...
I have configured TC to start with panels at selected certain folders.
After doing my job and going to various other folders, is it possible to go back to start position with one click?

I currently exit and restart TC to achieve this.
Thank you
You can automate the restart a little bit by let a DOS batch do the work.

-- Save the code to the TC folder as "Restart.CMD"

-- Create a button
CMD="D:\rive\path to\Restart.CMD
or better "%Commander_Path%\sub folder if any\Restart.CMD"
PARAM=
ICON=WCMICONS.DLL

Click that button to restart TC.
You may have to set TC configuration to not save current open tabs.



Restart.CMD

Code: Select all

@ECHO OFF
REM Stefan 2016, Restart currently running TC
REM http://ghisler.ch/board/viewtopic.php?t=47493
REM Call it from a TC button:
REM CMD="D:\rive\path to\this.cmd"
REM or better CMD="%Commander_Path%\sub folder if any\Restart.CMD"
REM PARAM=
REM ICON=WCMICONS.DLL
REM .........................................
REM COMMANDER_DRIVE=X:
REM COMMANDER_EXE  =X:\ToCo8\TOTALCMD.EXE
REM COMMANDER_INI  =X:\ToCo8\wincmd.ini
REM COMMANDER_INSTANCE=1
REM COMMANDER_PATH =X:\ToCo8

ECHO  Kill   %COMMANDER_EXE%
ECHO  EXE  : %COMMANDER_EXE%
ECHO  PATH : %COMMANDER_PATH%
REM Remove Com_Path from Com_Exe to get Exe-name only:
CALL SET TCExeName=%%Commander_EXE:%COMMANDER_PATH%\=%%
ECHO  myExe: %TCExeName%
ECHO.
ECHO.
ECHO Remove the line with PAUSE if you don't need THIS message.
ECHO Press Ctrl+C to cancel this script, or any key to restart TC...
ECHO.
PAUSE
TASKKILL /IM %TCExeName%
ECHO Launch %COMMANDER_EXE%
START "" %COMMANDER_EXE%
REM PAUSE



HTH? :D
User avatar
Horst.Epp
Power Member
Power Member
Posts: 6481
Joined: 2003-02-06, 17:36 UTC
Location: Germany

Post by *Horst.Epp »

sqa_wizard wrote:From the context menu of a tab select "Save tabs on both sides to file"
After this you have to create button with "OPENTABS <filename>"
With a click on this button you get back to start position.
To make that even better add this 2 em_command to your usercmd.ini

Code: Select all

[em_savealltabs]
cmd=SAVETABS2L %COMMANDER_PATH%\SAVETABS2L.tab
menu=Save all tabs to file

[em_OpenSavedTabs]
cmd=OPENTABS %COMMANDER_PATH%\SAVETABS2L.tab
menu=Open tabs from file

Then you can add buttons or entries in your menu or assign hotkeys to it.
No need to enter filename or use the tab context menu
Windows 11 Home x64 Version 23H2 (OS Build 22631.3447)
TC 11.03 x64 / x86
Everything 1.5.0.1372a (x64), Everything Toolbar 1.3.3, Listary Pro 6.3.0.73
QAP 11.6.3.2 x64
Fotis_Greece
Junior Member
Junior Member
Posts: 13
Joined: 2004-03-06, 14:07 UTC

Post by *Fotis_Greece »

sqa_wizard wrote:From the context menu of a tab select "Save tabs on both sides to file"
After this you have to create button with "OPENTABS <filename>"
With a click on this button you get back to start position.
Thank you very much. That does the trick. It may sound silly but i was unaware of the tabs existence.
May I kindly ask, is it possible when pressing that button (which loads the mystart.tab as I have named) NOT to show the tabs actually? I have a rather small laptop screen and would like to keep it minimal.
Thanks in advance and best regards from Greece
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

If you save tabs when you have no tabs, TC will restore only panel paths, w/o tabs.

You can use e.g. SAVETABS2L <filename> command from buttonbar button in order to save paths w/o tabs, and of course you can edit saved file and remove extra tabs from it. The only thing to mention: if you save tabs while right panel is active, OPENTABS will flip panels.
Fotis_Greece
Junior Member
Junior Member
Posts: 13
Joined: 2004-03-06, 14:07 UTC

Post by *Fotis_Greece »

It is now perfect, thank all very much
User avatar
petermad
Power Member
Power Member
Posts: 14795
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

2Fotis_Greece

If you don't use tabs then this button is easier to use:

Code: Select all

TOTALCMD#BAR#DATA
cd C:\

%COMMANDER_EXE%,1
Go to Start
F:\

-1
Just replace C:\ and F:\ with the two start directories of you choice.

You can just copy the green code here above to Clipboard and then right click on TC's button bar and choose Paste - then the button will be made for you. Make sure you have the cursor in the left file panel when you press the button - otherwise the two directories wil be swapped.
Last edited by petermad on 2017-03-14, 20:29 UTC, edited 2 times in total.
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
Fotis_Greece
Junior Member
Junior Member
Posts: 13
Joined: 2004-03-06, 14:07 UTC

Post by *Fotis_Greece »

That is even easier, thank you very much Peter.
Post Reply