I want to create a BATCH file, which opens a specified folder with Total Commander. But there are 2 possibility:
- if there is no running TotalCommander --> a new TotalCommander will start and open the folder
- if there is an already running TotalCommander --> open the folder with the running TC, and do not start a new TotalCommander
I have a code, which opens the folder with TotalCommander, but it always start a new TotalCommander, and not using the running one:
@echo off
SET totalc="C:\totalcmd\TOTALCMD.EXE"
set folder="C:\temp"
ECHO opening %folder% with %totalc%
%totalc% %folder%
ECHO opened
Is there any solution, to resolve this?