Is this WiX 2 or 3?

With WiX 2 I would assume you should write 

<CustomAction Id="ValidInstall" Error="$(loc.SomeErrorMessagLabel)" />

Rennie 



> -----Original Message-----
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of 
> Cristian Baiu
> Sent: 7. juni 2007 09:57
> To: wix-users@lists.sourceforge.net
> Subject: [WiX-users] How to use a localized string for an 
> error text of ancustom action
> 
> Hello,
> 
> I need to use in my project an custom action which displays 
> an error message and aborts installation in some specific 
> conditions. In order to achieve this I wrote the following line:
> 
> <CustomAction Id="ValidInstall" Error="Some error message"/>
> 
> If I place this custom action in the InstallExecuteSequence 
> and everything works as I was expecting. When my conditions 
> are not met, the "Some error message" is displayed and 
> installation aborted.
> 
> Now, I want to use a localized string as the error message in 
> order to be able to display the message in different 
> languages. For this I have added in a wxl file the following 
> String block:
> 
>  <String Id="MyErrMessage" Overridable="yes">Some error 
> message</String>
> 
> and I have modified my CustomAction block as follows:
> 
> <CustomAction Id="ValidInstall" Error="[MyErrMessage]"/>.
> 
> The project builds fine, but when I run my setup it fails 
> with the following error: "The installer has encountered an 
> unexpected error installing this package. This may indicate a 
> problem with this package. The error code is 2869".
> 
> Could you please advise me of what I did wrong and if it's 
> possible and how to achive what I need ?
> 
> Thanks,
> Cristian Baiu
> 
> --------------------------------------------------------------
> -----------
> 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
> WiX-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wix-users
> 

-------------------------------------------------------------------------
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
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to