FAQs: TCs' internal commands - how-to find and use them

English support forum

Moderators: sheep, Hacker, Stefan2, white

Post Reply
User avatar
Stefan2
Power Member
Power Member
Posts: 2640
Joined: 2007-09-13, 22:20 UTC
Location: Europa

FAQs: TCs' internal commands - how-to find and use them

Post by *Stefan2 » 2014-11-06, 10:23 UTC

How to find and use TCs' internal command

TCs' internal commands are listed in a file named "TOTALCMD.INC" in the TC folder.
Open it in Notepad to inspect the commands. (In TC, select the file and press F3 or F4 key on your keyboard)
(Alternatively you can also type 'cm_CommandBrowser' into the TC command line bar to open the 'Command Browser')


For example, I searched for command to un-select/de-select every file and folder again.

So I opened the "TOTALCMD.INC" and searched for "selec"
as part of a command name I was imagine it would be named like this,...
and then I found this line:
cm_ClearAll=524;Unselect all (files+folders)

Explanation:
This "cm_ClearAll" is the internal command I searched for.
"524" is the internal command number you can use too at some places.




How to use a TC internal command

There are several ways to use this command:

A)
Assign a keyboard shortcut to that command:
Menu "Configuration > Options... > Misc."
Choose [X] Control + [X] Alt + A
Command: <click at the lupe and choose cm_ClearAll>
[OK]


Explanation:
As Ctrl+A is the shortcut to SELECT ALL,
so Ctrl+Alt+A fits well for this DEselect command.
You could also choose Ctrl+/ (The NumPad ./. key)
as "NumPad ./." is assign to "cm_RestoreSelection=529;Restore last Selection"

- - - - -

B)
Use it in a menu file:
TotalCommander\LANGUAGE\WCMD_ENG.MNU
MENUITEM "Unselect all files + folders\tABCD+EFG+H", 524

Explanation:
"\t" will insert a tab for horizontal adjustment of the shortcut.
Instead of "ABCD+EFG+H" you could write the shortcut you have assigned to that command.
"524" or "cm_ClearAll" is the command to be executed.


- - - - -

C)
Add an button to the button bar to execute that command:
- right mouse click at the button bar >> Change...
- click at [Add] on the left
- Command: <click at the lupe, or just type: cm_ClearAll>
- Parameters: <empty>
- Start path: <empty>
- Icon file: %Commander_Path%\WCMICONS.DLL
- Icon: <chose one you like>
- Tooltip: cm_ClearAll; Unselect all (files+folders)
[OK]

Explanation:
“WCMICONS.DLL” holds some icons for us to use.


Another default resource are e.g.

Code: Select all

%windir%\system32\SHELL32.dll       (Windows Shell Common)
%windir%\system32\imageres.dll      (Windows Image Resource)
%windir%\system32\ieframe.dll       (Internet Explorer)
%windir%\system32\wmploc.dll        (Windows Media Player)
%windir%\system32\setupapi.dll      (Windows Setup API)
%windir%\system32\wscript.exe
%windir%\hh.exe                     (HTML Help sign)
%windir%\system32\regedit.exe
%windir%\system32\shdocvw.dll       (three shields: ! ? X)
%windir%\system32\wiashext.dll      (Imaging Devices)
%windir%\system32\mmres.dll         (General Audio Resources) 
%windir%\system32\comres.dll        (COM+ Resources)
%windir%\system32\wpdshext.dll      (Portable Devices, Arrows)
%windir%\system32\pifmgr.dll        (Windows NT PIF Manager)
%windir%\system32\moricons.dll      (Windows NT Setup, old DOS)
%windir%\system32\pnidui.dll        (Network System Icons)
%windir%\system32\netshell.dll      (Network Connections)
%windir%\system32\mmcndmgr.dll      (Management Console Node Manager)
%windir%\system32\ddores.dll        (Device Category Information and Resources)
%windir%\system32\compstui.dll      (Common Property Sheet, check, x, -, +, )
Thanks to: http://diymediahome.org/windows-icons-reference-list-with-details-locations-images/
More:
%windir%\system32\explorer.exe
%windir%\system32\accessibilitycpl.dll
%windir%\system32\gameux.dll
%windir%\system32\netcenter.dll
%windir%\system32\networkexplorer.dll

- - - - -

Always remember tp press the F1 key while you are in a dialog window to get more help.
Also, with the above keywords you are now able to search the forum for more information on this topic.


- - - - -

Short excerpt from TOTALCMD.INC file:

Code: Select all

[________________Source________________]=0
cm_SrcQuickview=304;Source: Quick view panel
cm_VerticalPanels=305;File windows above each other

[________________Left________________]=0
cm_LeftComments=100;Left: Show comments
cm_LeftShort=101;Left: Only file names

[________________Right________________]=0

[________________FileOperations________________]=0
cm_List=903;View with Lister
cm_PackFiles=508;Pack files

[________________Configuration________________]=0
cm_Config=490;Conf: Layout (first page)
cm_ChangeStartMenu=700;Change Start menu

[________________Network________________]=0
cm_NetConnect=512;Network connections
cm_AdministerServer=2204;Connect to admin share to open \\server\c$ etc.

[________________Misc________________]=0
cm_ExecuteDOS=511;Open command prompt window
cm_CompareDirs=533;Compare dirs

[________________ParallelPort________________]=0
cm_DirectCableConnect=2300;Connect to other PC by cable

[________________Print________________]=0
cm_PrintDir=2027;Print current directory (with preview)

[________________Mark________________]=0
cm_SelectFolders=3313;Select group: just folders
cm_SelectCurrentExtension=527;Select all files with same ext.

[________________Security________________]=0
cm_EditPermissionInfo=2200;Permissions dialog (NTFS)

[________________Clipboard________________]=0
cm_CopyToClipboard=2008;Copy selected files to clipboard
cm_CopyNamesToClip=2017;Copy filenames to clipboard
cm_CopyFullNamesToClip=2018;Copy names with full path
cm_CopyFileDetailsToClip=2036;Copy all shown columns

[________________FTP________________]=0
cm_FtpConnect=550;Connect to FTP
cm_FtpDownloadList=558;Download files in download list

[________________Navigation________________]=0
cm_DirectoryHistory=572;History list
cm_GoToRoot=2001;Go to root directory

[________________Window________________]=0
cm_Exit=24340;Exit Total Commander
cm_Maximize=2015;Maximize Total Commander

[________________CommandLine________________]=0
cm_ClearCmdLine=2004;Clear command line
cm_AddPathToCmdline=2019;Copy path to command line

[________________Tools________________]=0
cm_MultiRenameFiles=2400;Rename multiple files
cm_CommandBrowser=2924;Browse internal commands

[________________View________________]=0
cm_VisButtonbar=2901;Show/hide button bar

[________________User________________]=0
cm_UserMenu1=701;Start first menu item in Start menu

[________________Tabs________________]=0
cm_OpenNewTab=3001;Open new tab

[_______________Sorting______________]=0
cm_SrcSortByCol1=6001; Sort by first column

[________Custom column views_________]=0
cm_SrcCustomView1=271; Source: Custom columns 1

[________Commands with parameters_________]=0
;These negative numbers are just used for translation and cannot be used instead of the commands
CD <directory>=-2;Switch to the given directory
OPENTABS <filename>=-3;Open tabs from saved .tab file
FTPOPEN <conf. ftp server>=-5;Open stored ftp connection




Finde mich: TC-interne Kommandos (cm_xxx) / Befehlsbrowser cm_CommandBrowser
Find me:
Last edited by Stefan2 on 2015-07-18, 21:31 UTC, edited 1 time in total.
Inofficial FAQs || WIKI (Deu/Eng) || TC Home (What's new? // FAQ // Download // Order // Addons // Tools // Plugins)
Erst wenn der letzte Baum gefällt oder die letzte Biene verendet ist, werden die Leute verstehen warum Umweltschutz wichtig ist.

Post Reply