[WiX-users] Running .bat file during uninstall

2006-07-07 Thread Hecker, Thomas



Hi,

I need to run 
a .bat file that is installed with my product to undo some changes before the 
files are removed.

I tried the 
following code:

CustomAction 
Id="UninstallScript" Execute="commit" Directory='fw_bin' 
ExeCommand='services.bat uninstall' Return="check" /

InstallExecuteSequenceCustom 
Action='' Before='RemoveFiles'Installed/Custom 
/InstallExecuteSequence

But this results in 
a message "problem with installer package. A program required for this install 
to complete could not be run...".
The file is located in directory with ID "fw_bin". Is there a way to 
simply specify the complete path to execute?

What is the right 
way for doing this?
Thanks!

PS: Btw, how it's 
possibl to uninstall my "damaged" test-msi now? It does a 
rollback...
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users


Re: [WiX-users] environment variable available in executed program

2006-07-04 Thread Hecker, Thomas
Oh, thank you for this interesting idea!
But I think writing a little bootstrap .bat file is much less effort for my 
scenario. 

-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Im Auftrag von Strele Franz
Gesendet: Dienstag, 4. Juli 2006 15:54
An: WiX-users@lists.sourceforge.net
Betreff: Re: [WiX-users] environment variable available in executed program

hi,

have a look at the msdn-documentation for the Environment Table [1]:

Note that environment variables do not change for the installation in progress 
when either the WriteEnvironmentStrings action or RemoveEnvironmentStrings 
action are run. On Windows NT and Windows 2000, this information is stored in 
the registry and a message notifies the system of changes when the installation 
completes. A new process, or another process that checks for these messages, 
uses the new environment variables. On Windows 95 and Windows 98, this 
information is stored in the Autoexec.bat file, and do not affect the system 
until a system reboot.

you probably have a chance by sending a WM_SETTINGCHANGE (see [2]) via a custom 
action (after WriteEnvironmentStrings and RemoveEnvironmentStrings action). but 
i have not tried that and it may not work...

franz

[1] 
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/environment_table.asp
[2] 
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/sysinfo/base/wm_settingchange.asp

-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Im Auftrag von Rob Hamflett
Gesendet: Dienstag, 04. Juli 2006 14:31
An: wix-users@lists.sourceforge.net
Betreff: Re: [WiX-users] environment variable available in executed program

I had a similar thing with a new env var not being found by the program I was 
launching.  I can only conclude the following:

When you launch your MSI, it's value for PATH does not include your new folder. 
 The changes get committed to the system, but your MSI still has it's original 
set of env vars.  Since your batch file is run from the MSI, it has the same 
env vars, and so doesn't have the updated path.

Rob


Hecker, Thomas wrote:
 Hi,
  
 1) I'm adding my newly installed dir to the system path Environment 
 Id='env_entry' Name='PATH' Action='set' System='yes'
 Part='last' Permanent='no'  Value='[INSTALLDIR]share\bin' /
  
 2)  scheduled CA runs a .bat file that uses an executable from the 
 share\bin dir added to path.
  
 CustomAction Id='LaunchFile' FileKey='test.bat' 
 ExeCommand='-d [INSTALLDIR] ' Return='asyncNoWait' /
  
  InstallExecuteSequence
   Custom Action='LaunchFile' After='InstallFinalize'NOT 
 Installed/Custom  /InstallExecuteSequence
  
 3) In the up-popping console window I can see that the executable was 
 not found. But after opening a new cmd-session, it is available. Why 
 is that not in the console wix opens for me? How do I achieve this?
  
 Thank you very much,
 Thomas
 
 
 --
 --
 
 Using Tomcat but need to do more? Need to support web services, security?
 Get stuff done quickly with pre-integrated technology to make your job 
 easier Download IBM WebSphere Application Server v.1.0.1 based on 
 Apache Geronimo
 http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=1216
 42
 
 
 --
 --
 
 ___
 WiX-users mailing list
 WiX-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/wix-users


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier 
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642
___
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users