When you launch a program from the command prompt, the variables are remplaced before the program starts.... So %COMMANDER_PATH% is empty...
When you launch a program from the execute box in the start menu, the name of the variable is transfered to the program. In this case it's allright !
When you launch it from an autorun with the above settings, it seems that somehow TotalCommander don't get the correct parameters... I can't understand why
Code: Select all
[Autorun]
label=USB Key
icon=Tools\TotalCmd\Totalcmd.exe
action=Total Commander
action="@Tools\TotalCmd\Totalcmd.exe /L=%COMMANDER_PATH%\ /R=%SYSTEMDRIVE% /P=L"
open="Tools\TotalCmd\Totalcmd.exe /L=%COMMANDER_PATH%\ /R=%SYSTEMDRIVE% /P=L"
Shell=TotalCmd
Shell\TotalCmd=&Total Commander
Shell\TotalCmd\Command="Tools\TotalCmd\Totalcmd.exe /L=%COMMANDER_PATH%\ /R=%SYSTEMDRIVE% /P=L"
Code: Select all
[Autorun]
shell\test=Test
shell\test\command=test.bat /L=%COMMANDER_PATH%\ /R=%SYSTEMDRIVE% /P=L
Code: Select all
REM Test.bat
ECHO %1 %2 %3 %4 %5
PAUSE
Code: Select all
Z:\>REM TEST.BAT
Z:\>ECHO /L COMMANDER_PATH\ /R 1YSTEMDRIVE /P L
/L COMMANDER_PATH\ /R 1YSTEMDRIVE /P L
Z:\>PAUSE
Code: Select all
Z:\>REM TEST.BAT
Z:\>ECHO "/L=COMMANDER_PATH\ /R=1YSTEMDRIVE /P=L"
"/L=COMMANDER_PATH\ /R=1YSTEMDRIVE /P=L"
Z:\>PAUSE
I also tried to put this in Wincmd.ini...
Code: Select all
[left]
path=%COMMANDER_PATH%
[right]
path=%SYSTEM_DRIVE%
Any idea how I could solve the problem else than having to launch Tcmd trough a batch file that would popup for 1-2 seconds ?
Maybe Christian could consider the use of varibles to set the pannel path in wincmd.ini ?