lister file association

English support forum

Moderators: Hacker, petermad, Stefan2, white

Post Reply
ipwn
Junior Member
Junior Member
Posts: 8
Joined: 2011-11-23, 20:22 UTC
Contact:

lister file association

Post by *ipwn »

how can i make the lister open *.txt files when i double-click on them?
tpr
Junior Member
Junior Member
Posts: 37
Joined: 2011-06-05, 12:55 UTC

Post by *tpr »

"%COMMANDER_PATH%\totalcmd.exe" "/I=%COMMANDER_INI%" /S=L "%1"
ipwn
Junior Member
Junior Member
Posts: 8
Joined: 2011-11-23, 20:22 UTC
Contact:

Post by *ipwn »

tpr wrote:"%COMMANDER_PATH%\totalcmd.exe" "/I=%COMMANDER_INI%" /S=L "%1"
where should i add this, can you explain?
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, ipwn.

You go to Files => Internal Associations (Total Commander only) ...
Then you add an internal association for *.txt and assign it the commandline posted by tpr.

Kind regards,
Karl
ipwn
Junior Member
Junior Member
Posts: 8
Joined: 2011-11-23, 20:22 UTC
Contact:

Post by *ipwn »

karlchen wrote:Hello, ipwn.

You go to Files => Internal Associations (Total Commander only) ...
Then you add an internal association for *.txt and assign it the commandline posted by tpr.

Kind regards,
Karl
i've tried but when i open the *.txt the only thing that happens its opening a new total commander window..
i've managed to download lister (lister32.zip) and i assign *.txt to lister, can this be the solution?
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, ipwn.

I guess I have not checked the given commandline well enough before suggesting to use. :oops:
It should read

Code: Select all

"%COMMANDER_PATH%\totalcmd.exe" /O /S=L "%1"
The option /O will make sure that the internal lister will be opend by the running Total Commander instance and that no second Total Commander instance will be launched.

Kind regards,
Karl
ipwn
Junior Member
Junior Member
Posts: 8
Joined: 2011-11-23, 20:22 UTC
Contact:

Post by *ipwn »

karlchen, i've tried your sugestion with no sucess.. also i dont have %COMMANDER_PATH% variable in enviroment variables, i add the full path but it didnt work either.. what could be wrong?
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, ipwn.

Anybody who is running a more recent Total Commander version has got the T.C. internal variable %COMMANDER_PATH%. It points to the Total Commander programme folder. Therefore, it is alright to navigate to the file totalcmd.exe and use the hardcoded pathname instead of the variable.

Assuming you have installed T.C. inside "C:\Programe Files\Totalcmd" the commandline will be

Code: Select all

"C:\Programe Files\Totalcmd\totalcmd.exe" /O /S=L "%1"
The difference between the two commandlines

Code: Select all

"C:\Programe Files\Totalcmd\totalcmd.exe" /O /S=L "%1"
is that this commandline will only work in case Total Commander has been installed in "C:\Program files\Totalcmd", whereas the commandline

Code: Select all

"%COMMANDER_PATH%\totalcmd.exe" /O /S=L "%1"
will always work no matter which folder Totalcmd.exe lives in.

And make sure that inside Total Commander you use Files => Internal Associations (Total Commander Only)... and NOT Associate With ...

Kind regards,
Karl
ipwn
Junior Member
Junior Member
Posts: 8
Joined: 2011-11-23, 20:22 UTC
Contact:

Post by *ipwn »

i was using Files -> Associate With..., i have TT version 7.03 i dont see where is the option of Files -> Internal Associations...
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Congratulations
  1. Total Commander internal associations have been added in Total Commander v7.50. So T.C. internal file associations did not exist in Total Commander 7.03, yet. The current version is v7.56a, by the way.
  2. By using Associate with ... and messing around with it, you have very likely screwed up the Windows wide association of *.txt with the programme which used to open whenever you double clicked on a .TXT file inside Explorer.
In order to fix the Windows wide association you should launch Windows Explorer. Select a random .TXT file. Right click its name. Select "Always open with ..." and select the programme which you want to use for .TXT files outside Total Commander.

*.TXT in Total Commander

You have got two choices:
  1. Stick with Total Commander 7.03 and simply put up with pressing <F3> on a .TXT file in order to make lister come up and display the file.
  2. Download Total Commander v7.56a. And perform an Update installation.
    The update is free of cost.
    The update installation makes sure that all your current Total Commander settings will be preserved unmodified.
    Having updated to Total Commander v7.56a, you will be able to create a Total Commander internal association for *.TXT and tell it to run the commandline which I gave you.
Your choice.

Kind regards,
Karl
ipwn
Junior Member
Junior Member
Posts: 8
Joined: 2011-11-23, 20:22 UTC
Contact:

Post by *ipwn »

btw, there is any option to make lister to edit the text file?
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

No, natively there isn't any such option. Lister itself is a read-only file viewer.
Yet, again you have got the choice:
If you insist on using lister, then you can enhance its features by using a Total Commander lister plugin which can display and edit files, e.g. SynWrite.
If you'd rather use a standalone text editor, there are tons of them out there: PsPad if you want it fully featured or Notepad2 if you like it small.

Karl
ipwn
Junior Member
Junior Member
Posts: 8
Joined: 2011-11-23, 20:22 UTC
Contact:

Post by *ipwn »

thanks for the help.
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Good morning, ipwn.

May we assume that you have - one way or other - achieved your goal? For curiosity reasons: may we know what your solution is?
Have you upgraded to T.C. 7.56.a and created a Total Commander internal association for *.txt which opens the internal list whenever you double-click a .txt file?
Or are you clinging to Total Commander 7.03 and have created a Windows system-wide association which will launch the external T.C. lister whenever you double-click a .txt file?

Kind regards,
Karl
ipwn
Junior Member
Junior Member
Posts: 8
Joined: 2011-11-23, 20:22 UTC
Contact:

Post by *ipwn »

karlchen, i've uploaded to T.C. 7.56.a, and follow your instructions.
the thing is i feel that using TC is not very pratical as long as windows explorer exist, do you have some advice?
Post Reply