Sikatida Dovude wrote: 2019-12-17, 21:19 UTC
Hi!
I have to sort my files .. and move them to 3 different folders ...,
I want to select some similar type files and move them using for example "SHIFT + C" shortcut to "A-Directory" folder. ..
....
Hi, just some ideas:
You can create UserDefinedCommands "em_xxx" in usercmd.ini and assign a hotkey like "SHIFT + G" to execute them.
Such UDC can execute a script (Batch/PoSh/AutoHotkey/...) which take the list of selected files via TC-parameter like "%L" and do smtg with them (like copying)
Here is an example of an basic Batch for to adjust on each own needs:
Code: Select all
@echo off
REM Found at https://ghisler.ch/board/viewtopic.php?p=365186#p365186
REM Stefan 2019-12-18 v001
GOTO START
TotalCommander Button:
Commando : "%Commander_Path%\ForEachSelectedDO_ExampleBatch.cmd"
Parameters: "%L" "%P" "%T"
Start path:
Icon : C:\WINDOWS\System32\imageres.dll --or-- wcmicons.dll
Tooltip : ForEachSelectedDO_ExampleBatch
:START
REM Unicode file names: chcp 65001 ; Windows cp: CHCP 1250
ECHO ---------------------------- INFOs
ECHO TCs Param list: L or WL
ECHO L: %1
ECHO TCs Source folder: P
ECHO P: %~2
ECHO TCs Target folder: T
ECHO T: %~3
ECHO ---------------------------- DO IT
for /f "delims=" %%Z in ('type %1') do (
echo Do something with
echo %%Z
echo Name=%%~nxZ
echo BASE=%%~nZ
echo EXTE=%%~xZ
echo COPY form %2
echo TO %3
echo * * * * * * * * * * * * next file / line
)
ECHO ---------------------------- All done.
PAUSE
FAQs: User-Defined Command (UDC) (usercmd.ini) em_command AND Add shortcut key >>
viewtopic.php?f=3&t=52425
[em_MyCommandName]
cmd="%Commander_Path%\ForEachSelectedDO_ExampleBatch.cmd"
param="%L" "%P" "%T"
Here is an example script which ask for an target folder to copy the selected files on the fly into different folders:
VBScript: ForEachSelectedDO - ChooseTargetToCopyTo.vbs
- create a button with that script
- select a few files and click that button
- chose the wanted path number to copy to and click OK
viewtopic.php?p=338700#p338700
HTH?