SHORTCUT.lnk /k cd /d %P
where .lnk file just open "C:\Windows\System32\cmd.exe".
Now with Powershell beeing dominant in my work, i like to do just the same, only now with Powershell prompt?
So far i came up following, but it only opens powershell and 'verbosing' the correct current directory, but the actual directory is still
<PS C:\windows\system32> :
command = C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -noexit
syntax = -command "'%P'"
Parameters: -noexit -command "cd '%p'"
The command needs to be surrounded by double quotes " and %p by single quotes '
Just launch PowerShell.exe, TC will do the rest and ask PS to change to the path of the current active panel.
Code: Select all
Command = powershell -NoExit Parameters = Start path = Icon file = powershell Tooltip = Launch PS in current path
Ready to paste button:
Code: Select all
TOTALCMD#BAR#DATA powershell -NoExit powershell Launch PS in current path -1
O-m-goodness. The simplest solution is often the genius one. Thank you "Stefan2".Just launch PowerShell.exe, TC will do the rest and ask PS to change to the path of the current active panel.
And actually, my full question was how to open Powershell with elevated rights also. Thank you "obeg", you proved the best answer for my problem:
-noexit -command "cd '%p'"
Open the button for modifying > click [Help] and read:
1. You may specify ...........
.............. Put an asterisk '*' in front of the name to start it with administrative rights,
Command = *powershell -NoExit
Start path =
Icon file = powershell
Tooltip = Launch PS in current path as Admin
Luving Total Commander since Windows Commander....