- Использование запуска приложения с учетной записи администратора в Windows Server 2003
- Аннотация
- Действия, необходимые для запуска приложения с учетной записи администратора
- How to use Run as to start an application as an administrator in Windows Server 2003
- Summary
- Steps to start an application as an administrator
- Windows startup as administrator
- Answered by:
- Question
- How to auto start Programs as Administrator in Windows 10
- Auto start Programs as Administrator
- Windows startup — how to run a program as administrator from a batch file
Использование запуска приложения с учетной записи администратора в Windows Server 2003
В этой статье описывается использование команды для запуска Run as приложения в качестве администратора.
Исходная версия продукта: Windows Server 2003
Исходный номер КБ: 325362
Аннотация
Можно использовать для запуска приложения в качестве администратора, если вы хотите выполнять административные задачи при входе в систему в качестве члена другой группы, например «Пользователи» или Run as «Power Users».
Действия, необходимые для запуска приложения с учетной записи администратора
Чтобы запустить Run as приложение в качестве администратора, выполните следующие действия.
- Найдите приложение, которое нужно запустить в проводнике Windows, консоли управления (MMC) или панели управления.
- Нажимайте и удерживайте клавишу SHIFT, щелкнув правой кнопкой мыши исполняемый файл или значок приложения, а затем выберите «Запустить как».
- Выберите следующего пользователя.
- В полях «Имя пользователя»и «Пароль» введите учетную запись администратора и пароль, а затем выберите «ОК».
- Некоторые приложения могут не поддерживать использование Run as команды.
- Возможно, вы не сможете запустить приложение, консоль MMC или средство панели управления из сетевого расположения с помощью команды, если учетные данные, используемые для подключения к сетевой сети, отличаются от учетных данных, используемых для запуска Run as приложения. Учетные данные, используемые для запуска приложения, могут не разрешить доступ к одной сетевой сети.
- Вы также можете использовать Run as команду из командной строки. Для получения дополнительных сведений выберите «Начните» и выберите «Выполнить». В поле «Открыть» введите cmd и выберите «ОК». В командной подсказке введите runas /?, а затем нажмите ввод.
How to use Run as to start an application as an administrator in Windows Server 2003
This article describes how to use the Run as command to start an application as an administrator.
Original product version: В Windows Server 2003
Original KB number: В 325362
Summary
You can use Run as to start an application as an administrator if you want to perform administrative tasks when you are logged on as a member of another group, such as the Users or Power Users group.
Steps to start an application as an administrator
To use Run as to start an application as an administrator, follow these steps:
- Locate the application that you want to start in Windows Explorer, the Microsoft Management Console (MMC), or Control Panel.
- Press and hold down the SHIFT key while you right-click the executable file or the icon for the application, and then select Run as.
- Select The following user.
- In the User name and Password boxes, type the administrator account and password, and then select OK.
- Some applications may not support the use of the Run as command.
- You may not be able to start an application, MMC console, or Control Panel tool from a network location by using the Run as command if the credentials that are used to connect to the network share are different from those used to start the application. The credentials that are used to run the application may not permit you access to the same network share.
- You can also use the Run as command from the command line. For more information, select Start, and then select Run. In the Open box type cmd, and then select OK. At the command prompt, type runas /?, and then press ENTER.
Windows startup as administrator
This forum has migrated to Microsoft Q&A. Visit Microsoft Q&A to post new questions.
Answered by:
Question
I have a batch file that runs on start-up that prompts the user for the name of the laptop (each laptop has a unique ID). The WMIC command is called to rename the computer and user account to whatever the name of the laptop happens to be. It then maps a network drive to read from a text file which looks up which Win7 CD Key it should use, and then runs slmgr.vbs -ipk and -ato.
The current user account is an «Administrator» but when running the WMIC or SLMGR.VBS commands, it fails because it’s not the Administrator.
I have tried placing the script into the Logon/Logoff policy but the script didn’t even run when doing that. I’ve tried using Schedule Tasks, but because of the username and computer name changes, that causes errors. I’ve tried adding the script to HKEY_CU\Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers\ and setting the RUNASADMIN flag but that also didn’t work.
How do I force the command prompt window to run as an administrator and then execute the script?
How to auto start Programs as Administrator in Windows 10
We know how you can make programs run on startup and how you can make a program always Run as Administrator. Today, in this post we will see how you can auto-start Programs as an administrator in Windows 10; that means the program start on every Windows boot with elevated privileges.
Auto start Programs as Administrator
Creating a Program Shortcut, opening its Properties, opening the Compatibility tab, checking Run this program as an administrator and placing this shortcut in the Windows Startup folder does not work. What you will have to do, is make use of the Windows Task Scheduler to create an elevated Shortcut to run Programs bypassing the UAC Prompt.
So let us see how to make programs always run or auto start as administrator, with elevated privileges.
To begin with this, type Schedule Tasks in Start Search and hit Enter to open the Task Scheduler.
Under the General tab, give the Task a name, say NoUAC1, complete the other fields as required and make sure that you check the Run with highest privileges box.
Configure the setting under the Triggers, Action, Conditions & Settings tab according to your preferences. Under Trigger, you can set it to run when the computer starts every time. You can full details about this at our post on how to create elevated Shortcut to run Program bypassing UAC Prompt.
Once you have set up this task successfully, you will find that the program will start automatically with administrative privileges, every time your Windows PC boots.
You can also use freeware like UAC Trust Shortcut and Elevated Shortcuts to make things easier for you.
If you create shortcuts using these tools, you need to simply place the shortcuts in the Startup folder. More about these tools, at the end of this post.
I hope you can get this working for you. Additional inputs are, as usual, most welcome!
Windows startup — how to run a program as administrator from a batch file
On Windows 8.1, I am trying to start a program from a batch file which is called during startup and I want the program to run as Administrator. Here is what I do:
- I have a program prog.exe under c:\program files\MyProgram
- The EXE is flagged to «Run as Administrator»
- Under c:\program files\MyProgram there is a batch file called RunEXE.bat. It contains all sorts of things and the end it contains a line «start prog.exe»
- under «C:\programdata\Microsoft\Windows\Start Menu\Programs\StartUp» there is a shortcut to RunEXE.BAT.
- When I reboot the PC I expect the shortcut to launch the RunEXE.BAT which in turn will run PROG.EXE.
But it does not happen. There is a short «bleep» sound as if Windows is displaying a message asking to confirm the program should run as Administrator but nothing is visible on the screen.
a) If I flag the shortcut & exe NOT to run as admin, then the EXE is launched.
b) If I flag the shortcut & exe to run as admin, then the EXE is not launched.
c) If I flag the shortcut to NOT to run as admin and the EXE to run as admin then the EXE is launched but it does not run as administrator.
d) Startup shortcut to the EXE. (No batch). Shortcut not flagged to run as administrator, EXE is flagged: EXE not running.
e) Startup shortcut to the EXE. (No batch). Shortcut not flagged to run as administrator, EXE not flagged: EXE is running but not as administrator.
I tried disabling the UAC completely — same results. I also tried to have another EXE instead of the batch, with the same results.
So — is there a way to have a shortcut to an EXE from startup which will run an EXE as administrator?