OK, thanks again, that hint and a lot of searching finally got me to a
solution. Which is (this solution is for the case where default should
be a single-user install):
 
In the non-UI part of your project, place a definition similar to the
following:
 
    <Property Id="I_USERS">cur</Property>  <!-- cur or all -->

Do NOT try to define a default null value for the ALLUSERS property. As
far as I can determine it is not possible to define ALLUSERS to a null
value using a <Property> element. 
 
In the UI dialog box your radio buttons should look like this:
 
        <Control Id="UsersRBs" Type="RadioButtonGroup" X="26" Y="140"
Width="305" Height="45" Property="I_USERS" Text="I_USERS">
          <RadioButtonGroup Property="I_USERS">
            <RadioButton Value="cur" X="0" Y="0" Width="295" Height="16"
Text="Install for current user." />
            <RadioButton Value="all" X="0" Y="20" Width="295"
Height="16" Text="Install for all users." />
          </RadioButtonGroup>
        </Control>

And the Next pushbutton control should include these two lines:
 
          <Publish Property="ALLUSERS" Value="{}">I_USERS =
"cur"</Publish>  <!-- set null value -->
          <Publish Property="ALLUSERS" Value="1">I_USERS =
"all"</Publish>

That's it.
 
If I've misunderstood something I'd be very happy to hear about it.
 
Rennie
 
 



________________________________

        From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Rennie
Petersen
        Sent: 14. april 2007 21:19
        To: [EMAIL PROTECTED]
        Subject: Re: [WiX-users] ALLUSERS=0 (or null) not working
        
        
        Thanks.
         
        But how is it possible from a dialog box to choose "per-user"
and "per-machine" installs? 
         
        Can you define a property on-the-fly from a radio button
control?
         
        Are there examples of how to do this somewhere?
         
        (I know that Wise for Windows Installer somehow supports this.)
         
        Thanks again.
         
        Rennie
         


________________________________

                From: Bob Arnson [mailto:[EMAIL PROTECTED] 
                Sent: 14. april 2007 20:58
                To: Rennie Petersen
                Cc: [EMAIL PROTECTED]
                Subject: Re: [WiX-users] ALLUSERS=0 (or null) not
working
                
                
                Rennie Petersen wrote: 

                        When the ALLUSERS property is not defined I get
a per-user install. 

                        But when I define ALLUSERS and give it a value
of 0 then I get a per-machine install.


                For reasons long to the mists of time, ALLUSERS=0 isn't
a valid value; only 1, 2, and null are, per the ALLUSERS Property topic
in the MSI SDK.
                
                
                -- 
                sig://boB
                http://bobs.org <http://bobs.org> 

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
WiX-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to