$(var. ---) constructs are static, so all you're getting back is what you put 
in, which is the '*' in this place.  What you want is the generated product 
code, which is stored in the ProductCode property in the Property Table.

You should save [ProductCode] in you Registry element to get the effect you 
desire.

--
John Merryweather Cooper
Build & Install Engineer - ESA
Jack Henry & Associates, Inc.®
Shawnee Mission, KS  66227
Office:  913-341-3434 x791011
jocoo...@jackhenry.com
www.jackhenry.com



-----Original Message-----
From: Steve-Ogilvie [mailto:steven.ogil...@titus.com] 
Sent: Friday, August 22, 2014 8:41 AM
To: wix-users@lists.sourceforge.net
Subject: [WiX-users] create registry value with product code

Hi all,

I require to create a registry key with the product code, which I have set up 
like so:
in a Variable.wxi file:
<?define ProductCode = "*"?>

in my product.wxs I have:
<Product Id=&quot;$(var.ProductCode)&quot;

registry value as:
&lt;RegistryValue Type=&quot;string&quot; Name=&quot;Uninstall Command&quot; 
Value=&quot;msiexec /x $(var.ProductCode) /q&quot;/>

but after the install runs that registry value shows up as:
"msiexec /x * /q"

if I use:
<RegistryValue Type="string" Name="Uninstall Command" Value="msiexec /x 
[ProductId] /q"/>

it shows up as "msiexec /x  /q"

What am I doing wrong?

thanks,

Steve



--
View this message in context: 
http://windows-installer-xml-wix-toolset.687559.n2.nabble.com/create-registry-value-with-product-code-tp7596476.html
Sent from the wix-users mailing list archive at Nabble.com.

------------------------------------------------------------------------------
Slashdot TV.  
Video for Nerds.  Stuff that matters.
http://tv.slashdot.org/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users
NOTICE: This electronic mail message and any files transmitted with it are 
intended
exclusively for the individual or entity to which it is addressed. The message, 
together with any attachment, may contain confidential and/or privileged 
information.
Any unauthorized review, use, printing, saving, copying, disclosure or 
distribution 
is strictly prohibited. If you have received this message in error, please 
immediately advise the sender by reply email and delete all copies.


------------------------------------------------------------------------------
Slashdot TV.  
Video for Nerds.  Stuff that matters.
http://tv.slashdot.org/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to