<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>James Finnigan : LUA</title><link>http://blogs.msdn.com/jamesfi/archive/tags/LUA/default.aspx</link><description>Tags: LUA</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>The best way to make UAC shut up for a while</title><link>http://blogs.msdn.com/jamesfi/archive/2007/06/08/the-best-way-to-make-uac-shut-up-for-a-while.aspx</link><pubDate>Sat, 09 Jun 2007 06:25:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:3174222</guid><dc:creator>jamesfinnigan</dc:creator><slash:comments>2</slash:comments><comments>http://blogs.msdn.com/jamesfi/comments/3174222.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jamesfi/commentrss.aspx?PostID=3174222</wfw:commentRss><wfw:comment>http://blogs.msdn.com/jamesfi/rsscomments.aspx?PostID=3174222</wfw:comment><description>&lt;P&gt;Let's say you want to install a few things and want UAC to stop bugging you while you install them.&amp;nbsp; Should you turn off UAC and install the apps?&amp;nbsp; Since that disables UAC's virtualization, it can destabilize things that depend on data written to those virtual locations.&amp;nbsp; Here's an alternative that keeps all the virtualization intact while getting UAC to lay off for a while.&lt;/P&gt;
&lt;P&gt;Fire up gpedit.msc and adjust this policy (pictured below):&lt;/P&gt;
&lt;P&gt;&lt;A href="http://blogs.msdn.com/blogfiles/jamesfi/WindowsLiveWriter/ThebestwaytomakeUACshutupforawhile_11F33/image.png" atomicselection="true" mce_href="http://blogs.msdn.com/blogfiles/jamesfi/WindowsLiveWriter/ThebestwaytomakeUACshutupforawhile_11F33/image.png"&gt;&lt;IMG style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: 0px" height=575 alt=image src="http://blogs.msdn.com/blogfiles/jamesfi/WindowsLiveWriter/ThebestwaytomakeUACshutupforawhile_11F33/image_thumb.png" width=1103 border=0 mce_src="http://blogs.msdn.com/blogfiles/jamesfi/WindowsLiveWriter/ThebestwaytomakeUACshutupforawhile_11F33/image_thumb.png"&gt;&lt;/A&gt; &lt;/P&gt;
&lt;P&gt;Change it to be &lt;EM&gt;Elevate without prompting&lt;/EM&gt;:&lt;/P&gt;
&lt;P&gt;&lt;A href="http://blogs.msdn.com/blogfiles/jamesfi/WindowsLiveWriter/ThebestwaytomakeUACshutupforawhile_11F33/image_1.png" atomicselection="true" mce_href="http://blogs.msdn.com/blogfiles/jamesfi/WindowsLiveWriter/ThebestwaytomakeUACshutupforawhile_11F33/image_1.png"&gt;&lt;IMG style="BORDER-RIGHT: 0px; BORDER-TOP: 0px; BORDER-LEFT: 0px; BORDER-BOTTOM: 0px" height=511 alt=image src="http://blogs.msdn.com/blogfiles/jamesfi/WindowsLiveWriter/ThebestwaytomakeUACshutupforawhile_11F33/image_thumb_1.png" width=431 border=0 mce_src="http://blogs.msdn.com/blogfiles/jamesfi/WindowsLiveWriter/ThebestwaytomakeUACshutupforawhile_11F33/image_thumb_1.png"&gt;&lt;/A&gt; &lt;/P&gt;
&lt;P&gt;Of course, remember to turn it back when you're done! :)&lt;/P&gt;
&lt;P&gt;Cheers,&lt;/P&gt;
&lt;P&gt;James&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;[Update: how to do this without using gpedit.msc]&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;Run this command&amp;nbsp;(from an elevated&amp;nbsp;command prompt) to make UAC elevate without prompting:&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;reg ADD HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v ConsentPromptBehaviorAdmin /t REG_DWORD /d 0 /f&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;When you're done, run this command (from an elevated command prompt) to set it back to the default:&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;reg ADD HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v ConsentPromptBehaviorAdmin /t REG_DWORD /d&amp;nbsp;2 /f&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=3174222" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jamesfi/archive/tags/Tips/default.aspx">Tips</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/virtualization/default.aspx">virtualization</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/LUA/default.aspx">LUA</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/UAC/default.aspx">UAC</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/Setup/default.aspx">Setup</category></item><item><title>Making an MSI that doesn't need a UAC/LUA prompt</title><link>http://blogs.msdn.com/jamesfi/archive/2007/05/02/making-an-msi-that-doesn-t-need-a-uac-lua-prompt.aspx</link><pubDate>Thu, 03 May 2007 08:03:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:2387093</guid><dc:creator>jamesfinnigan</dc:creator><slash:comments>6</slash:comments><comments>http://blogs.msdn.com/jamesfi/comments/2387093.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jamesfi/commentrss.aspx?PostID=2387093</wfw:commentRss><wfw:comment>http://blogs.msdn.com/jamesfi/rsscomments.aspx?PostID=2387093</wfw:comment><description>&lt;H2&gt;The goal&lt;/H2&gt;
&lt;P&gt;I think that most things don't need to require a UAC prompt to install - just install it for that user.&amp;nbsp; Why not make the MSI so it doesn't prompt and your users get a smoother experience?&amp;nbsp; (Also, I feel much better installing a program that doesn't require elevation to install - at a minimum I know it's not disabling my anti-malware software.)&amp;nbsp; Ideally, with that same package you could optionally install per-machine (which requires elevation).&amp;nbsp; Here's some information on how to make it happen...&lt;/P&gt;
&lt;H2&gt;Background&lt;/H2&gt;
&lt;P&gt;I was recently asked to make an MSI for an &lt;EM&gt;extremely&lt;/EM&gt; minimal replacement of the &lt;EM&gt;Run As&lt;/EM&gt; menu item that was removed in Vista (by calling runas.exe).&amp;nbsp; Although I doubt we would ever ship something like that I decided to make an installation that didn't elevate, or that could elevate and install per-machine.&amp;nbsp; It was an interesting experience, although I didn't entirely get the behavior I was going for - there are some limitations that make it impossible to do with a&amp;nbsp;MSI in Windows Vista, but still possible in a single download.&amp;nbsp; (More on that later).&lt;/P&gt;
&lt;H2&gt;The technical details&lt;/H2&gt;
&lt;P&gt;All MSIs elevate on Windows Vista by default.&amp;nbsp; However there is a &lt;A href="http://msdn2.microsoft.com/en-us/library/aa372870.aspx" mce_href="http://msdn2.microsoft.com/en-us/library/aa372870.aspx"&gt;flag that you can set&lt;/A&gt; that will tell MSI that you don't need to elevate.&amp;nbsp; The 3rd bit of the word count summary property can be set by using the msiinfo tool (comes with the platform SDK).&amp;nbsp; Since I also used an embedded cab, that means my word count summary property should be set to 10 (8 | 2 == 10).&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;FONT face=Consolas size=2&gt;msiinfo RunAsNewUser.msi -w 10&lt;/FONT&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;You need to have the feature include both the per-user and per-machine information if you're trying to put both in one package like I did (not a best practice - more on that later).&amp;nbsp; &lt;/P&gt;&lt;PRE class=code&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;    &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Feature&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;RunAsNewUser&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Title&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;Run as New User&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Level&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;1&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
      &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;ComponentRef&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.runasnewuser.cmd&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
      &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;ComponentRef&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.runasnewuser.reg.exe&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
      &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;ComponentRef&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.runasnewuser.reg.msc&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
      &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;ComponentRef&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.cmd&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
      &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;ComponentRef&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.reg.exe&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
      &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;ComponentRef&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.reg.msc&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
    &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Feature&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&lt;FONT face=Consolas&gt;&amp;gt;
&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;
&lt;P&gt;Your standard MSI that installs to the system directories doesn't face the (fairly simple) issues involved.&amp;nbsp; Here's the per-machine version of my components (you need two versions of the components in order to put them in different directories(*). [I build all my MSIs using &lt;A href="http://wix.sourceforge.net/" mce_href="http://wix.sourceforge.net/"&gt;Wix&lt;/A&gt; - it gives me fine-grained control for making really solid MSIs and it tends to match the way I want to think about MSIs.]&lt;/P&gt;&lt;PRE class=code&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;      &amp;lt;!--&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,128,0)"&gt; We need a per-machine version as well, with seperate components &lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;--&amp;gt;
      &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;ProgramFilesFolder&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Name&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;AdTools&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
        &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.Microsoft&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Name&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;Microsoft&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
          &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.Runas&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Name&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;RunAs&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.runasnewuser.cmd&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Guid&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;9D448C8B-AF67-423B-9622-D9720770B61E&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;File&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.runasnewuser.cmd&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Name&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;runasnewuser.cmd&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;DiskId&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;1&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Source&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;runasnewuser.cmd&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;KeyPath&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;yes&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;&lt;/SPAN&gt;ALLUSERS&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.runasnewuser.reg.exe&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Guid&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;98A7DE3E-EF1D-434F-80CB-2F878CD0E9F5&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryKey&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.runasnewuser.reg.exe&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Key&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;SystemFileAssociations\.exe\shell\Run as new user...\command&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Root&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;HKCR&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Action&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;createAndRemoveOnUninstall&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
                &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryValue&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.runasnewuserCommand.exe&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Type&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;expandable&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Value&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;"[#pm.runasnewuser.cmd]" "%1" %*&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;KeyPath&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;yes&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;/&amp;gt;
              &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryKey&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;&lt;/SPAN&gt;ALLUSERS&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.runasnewuser.reg.msc&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Guid&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;20D758CC-2774-4532-BD6D-E7C378761C90&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryKey&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.runasnewuser.reg.msc&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Key&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;SystemFileAssociations\.msc\shell\Run as new user...\command&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Root&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;HKCR&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Action&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;createAndRemoveOnUninstall&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
                &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryValue&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pm.runasnewuserCommand.msc&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Type&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;expandable&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Value&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;"[#pm.runasnewuser.cmd]" "%1" %*&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;KeyPath&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;yes&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;/&amp;gt;
              &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryKey&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;&lt;/SPAN&gt;ALLUSERS&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
          &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
        &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
      &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&lt;FONT face=Consolas&gt;&amp;gt;
&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;
&lt;P&gt;Notice that I made these components conditional on &lt;FONT face=Consolas&gt;&lt;EM&gt;ALLUSERS&lt;/EM&gt;&lt;/FONT&gt;.&amp;nbsp; We'll make the per-user version conditional on &lt;FONT face=Consolas&gt;&lt;EM&gt;NOT (ALLUSERS)&lt;/EM&gt;&lt;/FONT&gt;.&amp;nbsp; This is pretty basic stuff, and is more or less simply specifying what goes where without much specialized stuff.&amp;nbsp; You can do a per-user setup that looks quite similar by putting it somewhere that isn't off the user's profile.&amp;nbsp; I decided to put mine in the user's profile which means a little extra baggage.&lt;/P&gt;
&lt;P&gt;So we're basically done right?&amp;nbsp; Well, not really, no.&amp;nbsp; We've disabled the elevation, but now you need to make your installation not require elevation.&amp;nbsp; Things like installing to &lt;EM&gt;Program Files&lt;/EM&gt; require admin rights, so we'll need to install to somewhere else.&amp;nbsp; I'm not really sure where that should be - probably %UserProfile%\ProgramFiles or something like that.&amp;nbsp; In this example, I installed to LocalAppData.&lt;/P&gt;&lt;PRE class=code&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;      &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;LocalAppDataFolder&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Name&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;AdTools&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
        &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.Microsoft&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Name&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;Microsoft&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
          &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.Runas&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Name&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;RunAs&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.cmd&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Guid&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;06A57A74-7639-4A96-A1FF-6C434ED50CEF&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;File&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.cmd&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Name&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;runasnewuser.cmd&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;DiskId&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;1&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Source&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;runasnewuser.cmd&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryValue&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.cmd.keypath&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Root&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;HKCU&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Key&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;Software\Microsoft\RunAs\KeyPaths&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Type&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;string&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Value&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;RunAsNewUser.cmd&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;KeyPath&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;yes&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RemoveFolder&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.Runas&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Directory&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.Runas&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;On&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;uninstall&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;/&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RemoveFolder&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.Microsoft&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Directory&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.Microsoft&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;On&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;uninstall&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;/&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;&lt;/SPAN&gt;NOT (ALLUSERS)&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.reg.exe&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Guid&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;C0DB0776-441A-4AB9-871A-5AF1F326FA0A&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryKey&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.reg.exe&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Key&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;SystemFileAssociations\.exe\shell\Run as new user...\command&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Root&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;HKCR&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Action&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;createAndRemoveOnUninstall&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
                &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryValue&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuserCommand.exe&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Type&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;expandable&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Value&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;"[#pu.runasnewuser.cmd]" "%1" %*&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
              &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryKey&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryValue&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.reg.keypath&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Root&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;HKCU&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Key&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;Software\Microsoft\RunAs\KeyPaths&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Type&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;string&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Value&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;RunAsNewUser.reg&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;KeyPath&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;yes&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;&lt;/SPAN&gt;NOT (ALLUSERS)&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.reg.msc&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Guid&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;C5B94A3B-7D87-4FC0-AC28-111B86679251&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryKey&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.reg.msc&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Key&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;SystemFileAssociations\.msc\shell\Run as new user...\command&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Root&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;HKCR&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Action&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;createAndRemoveOnUninstall&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
                &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryValue&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuserCommand.msc&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Type&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;expandable&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Value&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;"[#pu.runasnewuser.cmd]" "%1" %*&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
              &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryKey&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;RegistryValue&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Id&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;pu.runasnewuser.reg.msc.keypath&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Root&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;HKCU&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Key&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;Software\Microsoft\RunAs\KeyPaths&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Type&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;string&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;Value&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;RunAsNewUser.reg.msc&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(255,0,0)"&gt;KeyPath&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;=&lt;/SPAN&gt;'&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;yes&lt;/SPAN&gt;'&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt; /&amp;gt;
              &amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;&lt;/SPAN&gt;NOT (ALLUSERS)&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Condition&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
            &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Component&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
          &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
        &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face=Consolas&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&amp;gt;
      &amp;lt;/&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;Directory&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN style="COLOR: rgb(0,0,255)"&gt;&lt;FONT face=Consolas&gt;&amp;gt;&lt;/FONT&gt;
&lt;/SPAN&gt;&lt;/PRE&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;
&lt;P&gt;The extra baggage is the HKCU keypath RegistryValue, and the RemoveFolder entries.&amp;nbsp; Nothing crazy, but a little extra to be aware of.&amp;nbsp; These are necessary because of things like roaming profiles.&lt;/P&gt;
&lt;H2&gt;The experience&lt;/H2&gt;
&lt;P&gt;&amp;nbsp;You can install it and it goes through without any elevation.&amp;nbsp; The installation is per-user by default.&amp;nbsp; (Yay! Per-user works and has a smokin' experience, and supports all kinds of scenarios.)&lt;/P&gt;
&lt;P&gt;If you want to install it per-machine, you need to launch it via this command: &lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;FONT face=Consolas&gt;msiexec /i RunAsNewUser.msi ALLUSERS=1&lt;/FONT&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;This is obviously not ideal - but there's a hidden hiccup.&amp;nbsp; I thought that it would prompt for elevation if you specified ALLUSERS=1 - it does not.&amp;nbsp; You get this error message:&lt;/P&gt;
&lt;P&gt;&lt;IMG style="MARGIN: 5px" height=197 alt="You do not have sufficient privileges to complete this installation for all usrs of the machine." src="http://blogs.msdn.com/blogfiles/jamesfi/WindowsLiveWriter/MakinganMSIthatdoesntneedaUACLUAprompt_1361C/image_2.png" width=398 mce_src="http://blogs.msdn.com/blogfiles/jamesfi/WindowsLiveWriter/MakinganMSIthatdoesntneedaUACLUAprompt_1361C/image_2.png"&gt; &lt;/P&gt;
&lt;P&gt;It's not the end of the world.&amp;nbsp; If you run the same command from an already elevated process (e.g. an elevated command prompt) the installation goes through just fine (as the error message implies).&amp;nbsp; It's a bit of a shame, but I've confirmed with Carolyn that you can't build a single package that will elevate sometimes and sometimes not (because the flag is in the MSI summary information it can't be changed in-flight).&lt;/P&gt;
&lt;H2&gt;The best practice for building a per-user (without elevation) &lt;EM&gt;and &lt;/EM&gt;per-machine app (with elevation)&lt;/H2&gt;
&lt;P&gt;Because of the limitations noted above, here's what is the best practice for building a per-user &lt;EM&gt;and &lt;/EM&gt;per-machine app:&amp;nbsp; Have a bootstrapper exe, and two separate&amp;nbsp;MSIs (one per-user package and one per-machine package).&amp;nbsp; If these are embedded in the bootstrapper exe as resources that are extracted at install, then you can a single download that installs either as per-machine or per-user.&lt;/P&gt;
&lt;P&gt;Why?&amp;nbsp; Well, not many folks are trying to do this at the moment.&amp;nbsp; Of course, more will as Vista is on more and more computers - ultimately I think this is a huge step forward for keeping your computer free of malware.&amp;nbsp; I think it's worth saying twice: I feel much better installing a program that doesn't require elevation to install - at a minimum I know it's not disabling my anti-malware software.&lt;/P&gt;
&lt;H2&gt;Other Resources&lt;/H2&gt;
&lt;P&gt;&lt;A title=http://blogs.msdn.com/windows_installer_team/ href="http://blogs.msdn.com/windows_installer_team/" mce_href="http://blogs.msdn.com/windows_installer_team/"&gt;http://blogs.msdn.com/windows_installer_team/&lt;/A&gt;&amp;nbsp;- Get it straight from the horse's mouth&lt;/P&gt;
&lt;P&gt;&lt;A title=http://blogs.msdn.com/astebner/archive/2006/12/13/some-useful-things-i-have-learned-about-windows-installer-and-uac.aspx href="http://blogs.msdn.com/astebner/archive/2006/12/13/some-useful-things-i-have-learned-about-windows-installer-and-uac.aspx" mce_href="http://blogs.msdn.com/astebner/archive/2006/12/13/some-useful-things-i-have-learned-about-windows-installer-and-uac.aspx"&gt;http://blogs.msdn.com/astebner/archive/2006/12/13/some-useful-things-i-have-learned-about-windows-installer-and-uac.aspx&lt;/A&gt;&amp;nbsp;- Good intro article that doesn't bury you in information like Roberts' (great) blog entries&lt;/P&gt;
&lt;P&gt;&lt;A title=http://blogs.msdn.com/rflaming/archive/2006/10/01/uac-in-msi-notes-answers-to-questions-in-comments-from-earlier-blog-posts.aspx href="http://blogs.msdn.com/rflaming/archive/2006/10/01/uac-in-msi-notes-answers-to-questions-in-comments-from-earlier-blog-posts.aspx" mce_href="http://blogs.msdn.com/rflaming/archive/2006/10/01/uac-in-msi-notes-answers-to-questions-in-comments-from-earlier-blog-posts.aspx"&gt;http://blogs.msdn.com/rflaming/archive/2006/10/01/uac-in-msi-notes-answers-to-questions-in-comments-from-earlier-blog-posts.aspx&lt;/A&gt;&amp;nbsp;- Summary of Robert's huge series about MSI and UAC&lt;/P&gt;
&lt;P&gt;&lt;A href="http://blogs.msdn.com/rflaming/archive/2006/09/30/778690.aspx"&gt;http://blogs.msdn.com/rflaming/archive/2006/09/30/778690.aspx&lt;/A&gt;&amp;nbsp;- Robert gives his take on the question: Should I write my installer as a Standard User install? If yes, how?&lt;/P&gt;
&lt;HR&gt;

&lt;P&gt;*&amp;nbsp;I imagine that you don't really need two versions of the components because I imagine that you could change the directory location using a custom action that set it, but I just found things a lot simpler if I used two different components&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=2387093" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jamesfi/archive/tags/malware/default.aspx">malware</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/Tips/default.aspx">Tips</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/LUA/default.aspx">LUA</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/UAC/default.aspx">UAC</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/Setup/default.aspx">Setup</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/Wix/default.aspx">Wix</category></item><item><title>How to launch an un-elevated process from an elevated process</title><link>http://blogs.msdn.com/jamesfi/archive/2007/04/11/how-to-launch-an-un-elevated-process-from-an-elevated-process.aspx</link><pubDate>Thu, 12 Apr 2007 07:11:03 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:2095260</guid><dc:creator>jamesfinnigan</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jamesfi/comments/2095260.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jamesfi/commentrss.aspx?PostID=2095260</wfw:commentRss><wfw:comment>http://blogs.msdn.com/jamesfi/rsscomments.aspx?PostID=2095260</wfw:comment><description>&lt;p&gt;This question has come up a fair amount lately.&amp;nbsp; The short answer is that you don't&lt;strong&gt;*&lt;/strong&gt;&amp;nbsp;- instead you should:&lt;/p&gt; &lt;ol&gt; &lt;li&gt;first launch an unelevated process&lt;/li&gt; &lt;li&gt;have that unelevated process launch an elevated process and wait for it to finish (or use some form of IPC)&lt;/li&gt; &lt;li&gt;have that unelevated process then do what you wanted the elevated process to un-elevate and do&lt;/li&gt;&lt;/ol&gt; &lt;p&gt;OK, but why?&amp;nbsp; When you elevated there's a good chance that you &lt;em&gt;also changed users&lt;/em&gt;.&amp;nbsp; If you simply had a way to generate the split token associated with the elevated user, then you would be running as the wrong user.&lt;/p&gt; &lt;p&gt;This is all documented, of course, in the &lt;em&gt;&lt;a href="http://www.microsoft.com/downloads/thankyou.aspx?familyId=ba73b169-a648-49af-bc5e-a2eebb74c16b&amp;amp;displayLang=en"&gt;Windows Vista Application Development Requirements for User Account Control Compatibility&lt;/a&gt;&lt;/em&gt; document (I hate sentence names).&lt;/p&gt; &lt;p&gt;&lt;strong&gt;&lt;strong&gt;*&lt;/strong&gt; Caveat:&amp;nbsp; &lt;/strong&gt;There is still a way to launch a process as that original user with the split token - use task scheduler (see the linked document for the source code).&amp;nbsp; I don't recommend using task scheduler (I recommend the process above), but there are times when your choices are limited.&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=2095260" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jamesfi/archive/tags/Vista/default.aspx">Vista</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/Tips/default.aspx">Tips</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/LUA/default.aspx">LUA</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/UAC/default.aspx">UAC</category></item><item><title>UAC UI on oldnewthing - what the colors mean</title><link>http://blogs.msdn.com/jamesfi/archive/2007/03/31/uac-ui-on-oldnewthing-what-the-colors-mean.aspx</link><pubDate>Sun, 01 Apr 2007 01:08:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:2001778</guid><dc:creator>jamesfinnigan</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jamesfi/comments/2001778.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jamesfi/commentrss.aspx?PostID=2001778</wfw:commentRss><wfw:comment>http://blogs.msdn.com/jamesfi/rsscomments.aspx?PostID=2001778</wfw:comment><description>&lt;P&gt;I mentioned recently that I was the new owner of the UAC UI (from the dev side).&amp;nbsp; Well, today I found that &lt;A href="http://blogs.msdn.com/oldnewthing/archive/2007/03/30/1991616.aspx" mce_href="http://blogs.msdn.com/oldnewthing/archive/2007/03/30/1991616.aspx"&gt;Raymond Chen's blog&lt;/A&gt; has brought up the topic of what the colors mean.&amp;nbsp; I hadn't even really noticed that the dialogs changed much before taking ownership of the code, and due to the ease of repurposing attacks there is little comfort in seeing that a particular item is signed.&amp;nbsp; It's a good first pass, but I definitely think we have room for improvement in creating valuable distinctions&amp;nbsp;and conveying that information to the user.&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=2001778" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jamesfi/archive/tags/LUA/default.aspx">LUA</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/UAC/default.aspx">UAC</category></item><item><title>New Beginnings...</title><link>http://blogs.msdn.com/jamesfi/archive/2007/03/14/new-beginnings.aspx</link><pubDate>Wed, 14 Mar 2007 20:09:06 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1881643</guid><dc:creator>jamesfinnigan</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/jamesfi/comments/1881643.aspx</comments><wfw:commentRss>http://blogs.msdn.com/jamesfi/commentrss.aspx?PostID=1881643</wfw:commentRss><wfw:comment>http://blogs.msdn.com/jamesfi/rsscomments.aspx?PostID=1881643</wfw:comment><description>&lt;p&gt;I've moved onto the Windows&amp;nbsp;Experience team.&amp;nbsp; It should a lot of fun to continue to follow Guided Help, and some of my other projects but my emphasis now is on the&amp;nbsp;Windows Experience&amp;nbsp;- things like explorer and the like.&amp;nbsp; I'm also the new owner of the &lt;a href="http://windowsvistablog.com/blogs/windowsvista/archive/2007/01/25/accessible-uac-prompts.aspx"&gt;LUA/UAC shell UI&lt;/a&gt;, which should be interesting.&amp;nbsp; &lt;/p&gt; &lt;p&gt;This will probably change the kinds of things that I blog about - you can expect more shell-related topics, as well as various user experience discussions.&lt;/p&gt; &lt;p&gt;We have a lot of changes that we're excited about, and I look forward to building on Windows Vista.&amp;nbsp; &lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=1881643" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/jamesfi/archive/tags/Moving/default.aspx">Moving</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/Microsoft/default.aspx">Microsoft</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/LUA/default.aspx">LUA</category><category domain="http://blogs.msdn.com/jamesfi/archive/tags/UAC/default.aspx">UAC</category></item></channel></rss>