PATH= in INI file doesn't support variable

Here you can propose new features, make suggestions etc.

Moderators: Hacker, petermad, Stefan2, white

Post Reply
User avatar
eugensyl
Power Member
Power Member
Posts: 564
Joined: 2004-06-03, 18:27 UTC
Location: România
Contact:

PATH= in INI file doesn't support variable

Post by *eugensyl »

In [left] or [right] section of INI file if I set

PATH=%windir%

doesn't work. Only an explicity path will work: PATH=d:\Windows

In [lefttab] or [righttab] section works fine.

Maybe is not a bug. But I'd like to be available in next release.
My Best Wishes,

Eugen
User avatar
Clo
Moderator
Moderator
Posts: 5731
Joined: 2003-12-02, 19:01 UTC
Location: Bordeaux, France
Contact:

Not supported

Post by *Clo »

2eugensyl

:) Hello Eugen !

• The supported variables are listed HERE, and this one is not part of the list…
• So, I'ld consider that as a suggestion.

:mrgreen: KR
Claude
Clo
#31505 Traducteur Français de TC French translator Aide en Français Tutoriels Français English Tutorials
User avatar
Clo
Moderator
Moderator
Posts: 5731
Joined: 2003-12-02, 19:01 UTC
Location: Bordeaux, France
Contact:

Add a suggestion

Post by *Clo »

[mod]Thread moved to TC7 Suggestions
Clo, moderator.[/mod]
#31505 Traducteur Français de TC French translator Aide en Français Tutoriels Français English Tutorials
User avatar
eugensyl
Power Member
Power Member
Posts: 564
Joined: 2004-06-03, 18:27 UTC
Location: România
Contact:

Re: Not supported

Post by *eugensyl »

Clo wrote:2eugensyl

:) Hello Eugen !

• The supported variables are listed HERE, and this one is not part of the list…
• So, I'ld consider that as a suggestion.

:mrgreen: KR
Claude
Clo
Thanks for the quick answer.
Ok. It is a suggestion.

But the link is broken.
My Best Wishes,

Eugen
User avatar
Clo
Moderator
Moderator
Posts: 5731
Joined: 2003-12-02, 19:01 UTC
Location: Bordeaux, France
Contact:

Not broken !

Post by *Clo »

:arrow: eugensyl

:) Again…

• The link works OK from here at the moment…
You could download the Tuto also from my signature link (as CHM or HTML sources). ;)

:mrgreen: KR
Claude
Clo
#31505 Traducteur Français de TC French translator Aide en Français Tutoriels Français English Tutorials
User avatar
Sir_SiLvA
Power Member
Power Member
Posts: 3379
Joined: 2003-05-06, 11:46 UTC

Post by *Sir_SiLvA »

the link works fine here too....
Hoecker sie sind raus!
User avatar
eugensyl
Power Member
Power Member
Posts: 564
Joined: 2004-06-03, 18:27 UTC
Location: România
Contact:

Re: Not broken !

Post by *eugensyl »

Clo wrote::arrow: eugensyl

:) Again…

• The link works OK from here at the moment…
You could download the Tuto also from my signature link (as CHM or HTML sources). ;)

:mrgreen: KR
Claude
Clo
From here not. NP.
BTW, %windir% is a system variable and it is not in that list.
I have tried with %$MYPICTURES% (from list) and the command PATH still don't work.

I want to load TC with a specific wincmd.ini with Right path somewhere. No way! Only in the root of the drive.
But, if I load tabs, saved before, with 1_path set with enviroment variable - IT'S WORK.
It's work also if I put exactly whole path. I have some personal files and folders on D: partitition and I don't want to use a very long path.

Maybe my english is not the best, but I tried to explain why I consider this a little oblivion, not a mistake or bug.

That it's!

Thank for the answer.
My Best Wishes,

Eugen
User avatar
ts4242
Power Member
Power Member
Posts: 2081
Joined: 2004-02-02, 20:08 UTC
Contact:

Re: Not broken !

Post by *ts4242 »

eugensyl wrote:I want to load TC with a specific wincmd.ini with Right path somewhere. No way!
even if it is worked, it is not the correct way to start TC in specified path because TC will overwrite when closing

Try TC command line parameter R and/or L
User avatar
eugensyl
Power Member
Power Member
Posts: 564
Joined: 2004-06-03, 18:27 UTC
Location: România
Contact:

Re: Not broken !

Post by *eugensyl »

ts4242 wrote:
eugensyl wrote:I want to load TC with a specific wincmd.ini with Right path somewhere. No way!
even if it is worked, it is not the correct way to start TC in specified path because TC will overwrite when closing

Try TC command line parameter R and/or L
PLS try to edit file (wincmd.ini) with an external editor, not from inside of TC. (TC must be closed.) After that run TC.

You will see, I'm right.

PATH= command is made like this by design ? I don't think so...
It is an annoyance between first start of TC and load tabs, the same for example, whitch must have obvious the same behavior.

I remember, from history:
TC 7.02 RC1
02.09.07 Added: .tab files now also support environment variables like %temp% in path fields

I was surprised to see even in INI file at [Lefttabs] and [Righttabs] it's work this feature, since TC 7.02 RC1 .

Why not in PATH command too?

Mr. Ghisler - if you don't mind, please consider this in your to do list, as a new little feature:
02.09.0? Add: PATH command from most recent directory used, in INI file, now also support environment variables like %temp%

Don't worry, it's just a small wish...
:)

Thanks in advance!
My Best Wishes,

Eugen
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50541
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

It's supported in the [lefttabs] and [righttabs] fields only as a side effect, because environment variables are now supported when loading from external *.tab files - and these use the same load function as when loading the tabs from wincmd.ini.

The path field is a dynamic field and not meant to be set by the user.
Author of Total Commander
https://www.ghisler.com
User avatar
eugensyl
Power Member
Power Member
Posts: 564
Joined: 2004-06-03, 18:27 UTC
Location: România
Contact:

Post by *eugensyl »

ghisler(Author) wrote:It's supported in the [lefttabs] and [righttabs] fields only as a side effect, because environment variables are now supported when loading from external *.tab files - and these use the same load function as when loading the tabs from wincmd.ini.

The path field is a dynamic field and not meant to be set by the user.
Thanks for the answer!
Now I do not wait... You cut my hope.
:(

NP. I'll survive! :)
My Best Wishes,

Eugen
User avatar
Mikefield
Power Member
Power Member
Posts: 628
Joined: 2006-02-26, 19:13 UTC
Location: Oberursel, Germany HE

Post by *Mikefield »

Hello Christian!
ghisler(Author) wrote:It's supported in the [lefttabs] and [righttabs] fields only as a side effect, because environment variables are now supported when loading from external *.tab files - and these use the same load function as when loading the tabs from wincmd.ini.

The path field is a dynamic field and not meant to be set by the user.
I've made some changes in the Tabs on my U3 Stick today. One of these is, to point to "Eigene Dateien". The problem is now, that, depend of the Host where the Stick is connected, that the path to "Eigene Dateien" is changeable. So I've set the Tab to %$Personal%. The next step was to swap [left], [right], [lefttabs] and [righttabs] with the redirect function to tabs.ini and set the tabs.ini to read only. But when %$personal% is the active tab, it is not set by Total Commander after start. The variable %$personal% in [right] is not read / set correct, it points always to C:\. When I manual go to the Tab root (with ""), then it points to the correct path.

Did you have a way out of that?

Not sure is this a problem, but it is a suggestion to implement environment variables in the future. The drive letters to the U3 Stick are also changeable on different hosts. And if you have Tabs to the Stick you have to use the "U3_DEVICE_PATH". So it's not a good way to separate the Tabs and set them to read only.

mf

This didn't work (TC 7.50a, WinXP SP3):

Code: Select all

[right]
path=%$Personal%
ShowAllDetails=1
show=1
negative Sortorder=0
SpecialView=0
userspec=*b*.*
sortorder=0

[righttabs]
0_path=C:\Verschiedenes\
0_caption=Versch.
0_options=1|0|0|0|0|2|0
1_path=%U3_DEVICE_PATH%\Download\
1_caption=U3 DL
1_options=1|0|0|0|0|2|0
2_path=%U3_DEVICE_PATH%\Daten\
2_caption=U3 Daten
2_options=1|0|0|0|0|2|0
3_path=%AppData%\U3\00001680D7726B43\
3_caption=Host U3
3_options=1|0|0|0|0|2|0
activetab=0
activelocked=2
activecaption=Eigene
Bankster - Word of the Year 2009
StatusQuo
Power Member
Power Member
Posts: 1524
Joined: 2007-01-17, 21:36 UTC
Location: Germany

Post by *StatusQuo »

2Mikefield
Did you have a way out of that?
You could set the first tab active (C:\) and the second tab to %$PERSONAL%,
then write protect the INI file (or redirect the corresponding sections to write protect only those):

WINCMD.INI:

Code: Select all

[left]
RedirectSection=%COMMANDER_PATH%\PATH.INI
[right]
RedirectSection=%COMMANDER_PATH%\PATH.INI
[lefttabs]
RedirectSection=%COMMANDER_PATH%\PATH.INI
[righttabs]
RedirectSection=%COMMANDER_PATH%\PATH.INI
PATH.INI (write protected):

Code: Select all

[left]
path=c:\
[right]
path=c:\
[lefttabs]
0_path=%$PERSONAL%
0_options=1|0|0|0|0|1|0
activetab=0
[righttabs]
0_path=%$PERSONAL%
0_options=1|0|0|0|0|1|0
activetab=0
Who the hell is General Failure, and why is he reading my disk?
-- TC starter menu: Fast yet descriptive command access!
Post Reply