Running as Administrator?
Running as Administrator?
Is there a way to show, for example in the window caption, that a Salamander instance is running "as Administrator" (in Vista)?
Groente, Michel.
Re: Running as Administrator?
You can use command line parameters when starting AS (ie. prepare shortcuts for nonadmin and admin):
SALAMAND.EXE [-L directory] [-R directory] [-A directory] [-C reg_file] [-I icon_index] [-T title_prefix] [-O] [-P panel_index]
-I icon_index Specifies the icon color that will be used for main window. 0 means DEFAULT icon, 1 means RED icon, 2 means GREEN icon, and 3 means BLUE icon. You can also change the icon color in configuration of main window.
-T title_prefix Specifies the text prefix displayed in the title bar of main window. To suppress text prefix use the "" parameter. You can also change the prefix in configuration of main window.
SALAMAND.EXE [-L directory] [-R directory] [-A directory] [-C reg_file] [-I icon_index] [-T title_prefix] [-O] [-P panel_index]
-I icon_index Specifies the icon color that will be used for main window. 0 means DEFAULT icon, 1 means RED icon, 2 means GREEN icon, and 3 means BLUE icon. You can also change the icon color in configuration of main window.
-T title_prefix Specifies the text prefix displayed in the title bar of main window. To suppress text prefix use the "" parameter. You can also change the prefix in configuration of main window.
Re: Running as Administrator?
Salamanader doesn't do this automatically, but you can use command prompt parameters to add the prefix yourself or even change the icon color.
If you create two shortcuts - one normal and one admin (with "Run as admin" checkbox checked in the shortcut properties) with these prefixes, it will work for you.
So you can use:
Salamand.exe -I 1 -T Admin
to run your Salamander with red icon and Admin prefix in the window title.
EDIT: MartinS was a bit faster
If you create two shortcuts - one normal and one admin (with "Run as admin" checkbox checked in the shortcut properties) with these prefixes, it will work for you.
Code: Select all
Usage:
SALAMAND.EXE [-L path-to-left-panel] [-R path-to-right-panel] [-A path-to-active-panel] [-C use-configuration-file] [-I icon-index] [-T title-prefix] [-O only-one-instance] [-P panel-index]
Salamand.exe -I 1 -T Admin
to run your Salamander with red icon and Admin prefix in the window title.
EDIT: MartinS was a bit faster