About Searching for files by tags

English support forum

Moderators: white, Hacker, petermad, Stefan2

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

About Searching for files by tags

Post by *Spiderkeys »

I like to search mp3 by keywords (tags), and so far i've been using file comments to do this such as

I select a file, CTRL Z, then add something in the box like Country, Folk, Slow, Piano, Upbeat, then when I want to find something I click on Search for > Plugins, select Property to Comment, then OP: to Contains, then type in one of the keywords.

And if I want to search with more than 1 keyword, I just click More Rules and do the same thing as above, then I can feed results to Listbox.

It's works surprising well, no plugins are needed but obviously TC doesn't have a true built in feature of this, and wondering if there is an easier way.
User avatar
tuska
Power Member
Power Member
Posts: 3741
Joined: 2007-05-21, 12:17 UTC

Re: About Searching for files by tags

Post by *tuska »

Spiderkeys wrote:> ... wondering if there is an easier way.
My opinion is this:
* I would not type in file comments (Ctrl+Z), because genres can be queried, e.g. with the plugin "shelldetails"
* calling a saved search with a shortcut would make the query much easier

So I would recommend you the following:

Plugin "shelldetails": http://lefteous.totalcmd.net/tc/shelldetails_eng.htm
http://lefteous.totalcmd.net/tc/archives/shelldetails/wdx_shelldetails_1.25.zip <- start download now!
Double-clicking on the file wdx_shelldetails_1.25.zip installs the plugin.

Create and save a search query in TC
* ALT + SHIFT + F7 (call separate search window in TC)
* Leave the "Search for:" field blank
* "Search in:" field => Path input, only if search is to be narrowed down;
   Search in subdirectories: Search depth additionally also adjustable
* [x] 'Everything' (Option: Tick 'Everything')
* "Plugins" tab
* [x] Search in plugins (tick 'plugins')
* [x] OR (any match)
* Plugin: shelldetails > Property: Genre > OP - contains: > Value: Country > Button "More Rules"
* Plugin: shelldetails > Property: Genre > OP - contains: > Value: Folk
* "Load/Save" tab: > "Save" button > Template name: Music-Genre

Create em_commands and one AHK script to use e.g. Shortcut SHIFT + M to invoke the saved search


* Type in cm_CommandBrowser in the TC command line, then press <ENTER>
* Click on usercmd.ini (under "Category")
* Press the "New ..." button --- press OK twice after collection of data

em_Search_Music-Genre
Command: %COMMANDER_EXE%
Parameters: /S=F:LMusic-Genre
Start path: Leave empty
Icon file: wcmicons.dll, Icon: 47 or 57 or what you want
Tooltip: %COMMANDER_EXE% /S=F:LMusic-Genre

em_FilesSearch (AHK-Skript: Please see below...)
Command: %COMMANDER_PATH%\Tools\AutoHotkey\FilesSearch.AHK
Start path: %COMMANDER_PATH%\Tools\AutoHotkey\
Iconfile: %COMMANDER_PATH%\Tools\AutoHotkey\AutoHotkey.exe
Icon: 0
Tooltip: %COMMANDER_PATH%\Tools\AutoHotkey\FilesSearch.AHK

em_Music-Genre_SEARCH
Command: em_Search_Music-Genre,em_FilesSearch
Tooltip: em_Search_Music-Genre,em_FilesSearch

Define a shortcut for this em_command on e.g. SHIFT + M
Configuration > Options ... > Misc. > Redefine hotkeys (Keyboard remapping) - Hotkey:
* [x] Shift+ M
* Click on the magnifying glass
* Click on usercmd.ini
* Click on "em_Music-Genre_SEARCH", then press "OK"
* Attention: Click on the green arrow (next to magnifying glass) = save, press "OK" - DONE!

Auto-Hotkey script "FilesSearch.AHK"

(As a user: My very first and probably also last script created by myself :? )
Links: https://autohotkey.com/download/, https://autohotkey.com/docs/commands/Send.htm
Function: Ctrl+Tab, Ctrl+Tab, Tab, Tab, Tab, Tab, Tab -> so that the input field in the search is called directly ...
Script:

Code: Select all

Sleep 1000
Send ^{Tab 2}
Send {Tab 5}
Note / specifics:
Sleep xxx ... delay adjustable (do not set the time too short, otherwise the script will not work as desired)
Sleep 700 works for me with TC 64 bit + TC 32 bit
Send {Tab 5} for TC 64 bit
Send {Tab 6} for TC 32 bit

From now on, the saved search for genres can be called up with SHIFT + M.
In my opinion, the AHK script in combination with em_commands is also recommended when querying file comments (Ctrl + Z).

Regards
Karl
Post Reply