Possibility to include file in wincmd.ini?

English support forum

Moderators: white, Hacker, petermad, Stefan2

Post Reply
ktp
Junior Member
Junior Member
Posts: 17
Joined: 2014-03-16, 07:16 UTC

Possibility to include file in wincmd.ini?

Post by *ktp »

Hello you all,

I have a need for inclusion inside wincmd.ini, much like Server Side Include for html for knowledgeable users.
I just discover the User Start menu possibility ([user] section in wincmd.ini),
and I wonder whether there is a possibility to include other files inside it. For example:

In user1 wincmd.ini:
[user]
Include /common_path/common_menu.inc
Include /user1_path/user1_personal_menu.inc
[other_section]
....


In user2 wincmd.ini:
[user]
Include /common_path/common_menu.inc
Include /user2_path/user2_personal_menu.inc
[other_section]
....

By this, both user1 and user2 could use their shared common Total Commander installation directory and toolbar,
but with different user Start menu. Does Total Commander support this function?


Thank you.
User avatar
Stefan2
Power Member
Power Member
Posts: 4157
Joined: 2007-09-13, 22:20 UTC
Location: Europa

Re: Possibility to include file in wincmd.ini?

Post by *Stefan2 »

Perhaps you can utilize the "redirect a section to an another file"-feature ?

wincmd.ini
[user]
RedirectSection=D:\rive\path\Wincmd_User.INI








 
User avatar
white
Power Member
Power Member
Posts: 4617
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Re: Possibility to include file in wincmd.ini?

Post by *white »

[Help - Ini file Settings: Overview / Settings in the file wincmd.ini: Overview] wrote:
Using multiple ini files

There are two options which allow to redirect one or more section from wincmd.ini to other files, e.g. to make the main wincmd.ini read only. It's also possible to quickly delete volatile data like directory and command line history by putting them in a separate file, which can then be deleted regularly.

1. Global option in section [Configuration]:
AlternateUserIni=<somename.ini>
If present in section [Configuration], it will redirect storing of all user-changeable sections to an alternate ini file (in this example, somename.ini), except for the following sections: [Configuration], [Layout], [Packer], [Confirmation], [Extensions], [Associations], [Shortcuts], [ShortcutsWin], [PackerPlugins], [FileSystemPlugins], [ListerPlugins], [ContentPlugins].

2. All sections can be redirected individually:
In each section, an entry
RedirectSection=
can be added to change the default behaviour. It will allow to redirect (or not) this section to another ini file:
Possible values:
0: no redirect even if the section would be redirected by AlternateUserIni
1: redirect to ini file defined via AlternateUserIni=<alternate ini file.ini>
<ininame.ini>: redirect to that specific ini
To deactivate a section (e.g. one of the histories), redirect that section to a read-only file.

Note:
When RedirectSection is placed in the [Configuration] section, all variables of that section will be redirected, except for AlternateUserIni and UseIniInProgramDir, which will always be read from the main ini file.

3. All redirections MUST be in the MAIN (first) .ini file.
Redirections in secondary ini files will be ignored, as well as redirections in wcx_ftp.ini.
ktp
Junior Member
Junior Member
Posts: 17
Joined: 2014-03-16, 07:16 UTC

Re: Possibility to include file in wincmd.ini?

Post by *ktp »

Thank you all for your answers.
Finally I think the best way for me is to use Main menu change for common part, then each user uses his/her own wincmd.ini with [user] section.
Post Reply