Regristry edit to bypass UAC and Run as Admin in windows 7 ?
I am using print migrator to install a list of printer and drivers and I have a batch file that does all the work. We have a lot of lab stations that need to have printers added to them and it would be nice to automate it, instead of have to go and click each one (over 1000 stations). However I can not figure out the registry edit I need to add that will allow me to have "printmig /r printer.cab" bypass the UAC "are you sure" box and the the "right click, run as admin". What do I need to add that will allow me to run that command with bypassing both?
December 18th, 2009 4:42pm

If you want to go ahead and change the behavior of the Windows Security dialog using the registry, this is how you alter ConsentPromptBehavior. Launch regedit and navigate to:HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\SystemTrap: When you navigate to : HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System sub folder. The default value is : "ConsentPromptBehaviorAdmin" = dword:00000002. This means: Display the UAC dialog box Change to: "ConsentPromptBehaviorAdmin" = dword:00000000. Setting the value of "ConsentPromptBehaviorAdmin" to zero bypasses the new UAC interface and the administrative task completes without further user interaction. There is no need to even logoff, changes to "ConsentPromptBehaviorAdmin" are applied straight away. MCSE, MCSA, MCDST
Free Windows Admin Tool Kit Click here and download it now
December 18th, 2009 5:46pm

would this be just for the program or will this completely get rid of UAC? This is for a laptop batch file for our users and dont want to get rid of it completely, just for the Print Migrator.
December 18th, 2009 6:40pm

would this be just for the program or will this completely get rid of UAC? This is for a laptop batch file for our users and dont want to get rid of it completely, just for the Print Migrator. Hi TreyThis registry edit would disable the UAC prompt for anyone using an Administrator account.The only way I'm aware of to run a particular program and bypass the UAC prompt is by using the Task Scheduler. I'm not sure if this method would meet your needs, but it's worth taking a look to see how it works.See the following article for the step by step instructions. The article was written for Vista, but works equally well in Windows 7. Taming UAC Let us know.Thank You for using Windows 7 Ronnie Vernon MVP
Free Windows Admin Tool Kit Click here and download it now
December 18th, 2009 10:39pm

You need to follow the steps below on one of the Windows 7 computers to edit the policy to allow standard user accounts to install hardware drivers and apply this policy to all Windows 7 clients in the domain. Click Start, in the Start Search box type "gpedit.msc" and press Enter. Locate to "Computer configuration"->"Driver installation"->"Allow non-administrators to install drivers for these device setup" classes, double-click it. Select Enable, click Show…, then click Add…, enter the class ID {4D36E979-E325-11CE-BFC1-08002BE10318}. (brackets included.). Please perform the above steps to adjust the local policy on a problematic Windows 7 RC computer, then run the following command to refresh the policy change: Gpudate /force If you want, you can deploy this setting to many client computers by using a domain based GPO (instead of the local policy). However, if you are using Windows Server 2003 DC, the steps will be a little special. The above "Allow non-administrators to install drivers for these device setup" policy may not available on a Windows Server 2003-based DC, because it is not aware of the Windows 7 RC policies. As a workaround, you can create a domain based GPO, and do not open it on the DC. Instead, go to a Windows 7 RC client computer, run MMC, add the Group Policy snap-in, load the newly created domain GPO, and then adjust the "Allow non-administrators to install drivers for these device setup" settings.Arthur Xie - MSFT
December 21st, 2009 10:42am

Arthur, Even after appyling these steps to any standart vista computers,the users are still getting UAC prompt screen (asking the admin password) when they plug the usb printers when their computers. I know this forum is for Windows 7 but i have the same problem in Vista. How could i get rid of UAC screen when I plug a usb printer. Could you help me ? Regards Ergin
Free Windows Admin Tool Kit Click here and download it now
February 3rd, 2011 7:11am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics