Re: [WiX-users] Condition based on a string in custom action

2011-08-29 Thread Wilson, Phil
ARPINSTALLLOCATION is a property that people set to make their install location 
visible via supported MSI APIs.  It doesn't get persisted into the uninstall 
environment unless you persist it, and the same is true of CUSTOMDIR. What are 
you trying to accomplish here? 

Phil Wilson 


-Original Message-
From: Mark [mailto:m...@rcsal.com] 
Sent: Monday, August 29, 2011 2:10 PM
To: wix-users@lists.sourceforge.net
Subject: [WiX-users] Condition based on a string in custom action

have tried with and without CDATA tags, but can't get the behavior I want
regardless of what I do!


?xml version=1.0 encoding=utf-8?
Wix xmlns=http://schemas.microsoft.com/wix/2006/wi;
?define ProductName=myProdName ?
...
SetProperty Id=ARPINSTALLLOCATION Value=[CUSTOMDIR]
After=CostFinalize /
...
Custom Action=myCustAct After=RemoveFoldersInstalled AND NOT
UPGRADINGPRODUCTCODE AND
(ARPINSTALLLOCATION gt;lt; $(var.ProductName))
/Custom
...


The installation works beautifully, myCustAct is properly ignored on
installations and upgrades (as expected), but when doing a removal:
myCustAct always runs regardless of whether or not ARPINSTALLLOCATION
contains the var.ProductName !!!   It should only happen when the product
name is found in (a part of) the ARPINSTALLLOCATION string ... can someone
clue me in on how to correct this to get the behavior I'm after?

I've tried: 
with and without quotes, and while the installation always builds and runs
properly, 
I'm not getting the proper behavior on removal.   :(  Help? :)

--
View this message in context: 
http://windows-installer-xml-wix-toolset.687559.n2.nabble.com/Condition-based-on-a-string-in-custom-action-tp6739641p6739641.html
Sent from the wix-users mailing list archive at Nabble.com.

--
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better 
price-free! And you'll get a free Love Thy Logs t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
___
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users


*** Confidentiality Notice: This e-mail, including any associated or attached 
files, is intended solely for the individual or entity to which it is 
addressed. This e-mail is confidential and may well also be legally privileged. 
If you have received it in error, you are on notice of its status. Please 
notify the sender immediately by reply e-mail and then delete this message from 
your system. Please do not copy it or use it for any purposes, or disclose its 
contents to any other person. This email comes from a division of the Invensys 
Group, owned by Invensys plc, which is a company registered in England and 
Wales with its registered office at 3rd Floor, 40 Grosvenor Place, London, SW1X 
7AW (Registered number 166023). For a list of European legal entities within 
the Invensys Group, please go to http://www.invensys.com/en/legal/default.aspx.

You may contact Invensys plc on +44 (0)20 3155 1200 or e-mail 
recept...@invensys.com. This e-mail and any attachments thereto may be subject 
to the terms of any agreements between Invensys (and/or its subsidiaries and 
affiliates) and the recipient (and/or its subsidiaries and affiliates).



--
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better 
price-free! And you'll get a free Love Thy Logs t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
___
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users


Re: [WiX-users] Condition based on a string in custom action

2011-08-29 Thread Mark
Unless I'm totally off base, the line provided does persist
ARPINSTALLLOCATION in the unistall environment (it's being explicitly set
after CostFinalize regardless of whether this is an initial installation,
repair, an update, or a removal.)  Am I mistaken?


As for CUSTOMDIR, I didn't provide those lines because I didn't think they
were relevant... but it too has been explicitly set ... I store the value in
the registry when the product is installed, seed with that value from the
key retrieved if/when it is present (during updates, removals) - and when
the value is not present (initial installation) I provide a default value
which the person running the installation can override.


What I'm trying to accomplish: finding the proper syntax for the 3rd
condition I want to put on myCustAct:
 ARPINSTALLLOCATION  must contain var.ProductName in order for myCustAct to
execute.

I've tried: 



and a handful of similar lines for the condition, but regardless of what I
specify, MyCustAct always executes (as if the 3rd condition doesn't exist)
when I'm removing a previous installation...

IF ARPINSTALLLOCATION wasn't persisted, I would expect the condition to
always fail (as it would never contain my application's name) but it's doing
the opposite, it's always succeeding!  Even when the application name isn't
present in the path ... hence my problem.



--
View this message in context: 
http://windows-installer-xml-wix-toolset.687559.n2.nabble.com/Condition-based-on-a-string-in-custom-action-tp6739641p6740584.html
Sent from the wix-users mailing list archive at Nabble.com.

--
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better 
price-free! And you'll get a free Love Thy Logs t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
___
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users