How to pass param one by one to a program
Moderators: Hacker, petermad, Stefan2, white
How to pass param one by one to a program
I make a button with command:
mklink /J %T%N %P%N
The command can create a folder symbolic link.
I need create many folders symbolic link. like mklink /J %P%S %T%S, but mklink only support a file name as param.
My wish is:
1. select many folders in tc
2. for a folder in select folders:
mklink %T/folder %N/folder
this is a loop expression
I met a software can do the job, but I can't remember its name, someone can help me?
mklink /J %T%N %P%N
The command can create a folder symbolic link.
I need create many folders symbolic link. like mklink /J %P%S %T%S, but mklink only support a file name as param.
My wish is:
1. select many folders in tc
2. for a folder in select folders:
mklink %T/folder %N/folder
this is a loop expression
I met a software can do the job, but I can't remember its name, someone can help me?
- Vochomurka
- Power Member
- Posts: 816
- Joined: 2005-09-14, 22:19 UTC
- Location: Russia
- Contact:
Try this tool. I have List2Str with similar (but not the same) capabilities. I can find it neither on wincmd.ru, nor totalcmd.net. If you want, I can email it to you.
Single user license #329241
PowerPro scripts for Total Commander
PowerPro scripts for Total Commander
- Balderstrom
- Power Member
- Posts: 2148
- Joined: 2005-10-11, 10:10 UTC
Use a batch .cmd, like Script: MultiFileOpen.cmd
Modified for junction purposes:
Create a button:
To use, select Folders you want to create junctions for, and click the button.
Modified for junction purposes:
Create a button:
Put this in a file, TCmklink.cmdCommand: cmd.exe /c "C:\Location\of\TCmklink.cmd"
Params: %P %T %S
Code: Select all
@ECHO OFF
CLS
:: SET Source=%~1
:: SET Target=%~2
:_LOOP
IF "%~3"=="" GOTO:EOF
mklink /j "%~2%~3" "%~1%~3"
SHIFT /3
GOTO:_LOOP
Re: How to pass param one by one to a program
As suggested, you can use lst2multi, the script of Balderstrom or you can use tcbl.bbbslayer wrote:I make a button with command:
mklink /J %T%N %P%N
The command can create a folder symbolic link.
I need create many folders symbolic link. like mklink /J %P%S %T%S, but mklink only support a file name as param.
My wish is:
1. select many folders in tc
2. for a folder in select folders:
mklink %T/folder %N/folder
this is a loop expression
I met a software can do the job, but I can't remember its name, someone can help me?
TCBL is TC Bat Builder and launcher, you can get it here !
the command could be :
Code: Select all
program: tcbl
parameter -q %L mklink /J "%T\$n" "$f"
icon: Whatever you want
using * at beg of program TC launch with admin right.Lefteous wrote:Can anyone help me in creating a solution that includes executing an elevated version of cmd.exe?
Code: Select all
program:*%COMSPEC% /k
parameter: cd %P