Sorry to be bending your 'ears' with this. OK. I think I know what is happening now. It *IS* executing my custom action. The problem is, the binary executable that is supposed to get run (cabinstaller.exe) doesn't exist on the machine in the %temp% location, when the custom action is run.
Cabinstaller is added to the msi file with <Directory Id="TARGETDIR" Name="SourceDir"> <Directory Id="TempFolder" Name="TempDir"> <Component Id="INTAVADLLS" DiskId="1" Guid="$(env.INTAVADLSGUID)"> <File Id="CabInstaller.exe" Name="INSTALLR.EXE" LongName="CabInstaller.exe" src="<bld loc>\CabInstaller.exe" Vital="yes" /> During an install, it gets placed, by the installer, in the %temp% directory, where the install custom actions can execute it. After it gets executed for the install, it gets deleted by another custom action (not allowed to leave the executable or the cabs behind), after it has been used. I am guessing that the installer doesn't bother copying the files to the %temp% directory during an uninstall (I suspect it just doesn't complain about them not being there when it goes to delete them). Thus the executable is NOT on the machine where my custom action bat file is expecting it to be. This would also explain WHY I was getting an unexpected return value error when I tried to run it directly from the installer. I thought it was throwing an exception which the installer was catching and which (for some reason I couldn't). What I now suspect was happening is, since the file did NOT exist on the machine, the custom action simply could not execute it couldn't be found to execute). It wasn't throwing an exception at all (the reason for the bat file in the first place). So, now the question becomes: HOW do I execute it, when it has NOT been copied onto the target machine. It is (it must be, as it is available during install) in the msi file. Is there a way to execute it from inside the msi file (and HOW)? Or is there a way to get it to be copied to the %temp% directory so it can run it? By the way, MANY thanks for the helpful suggestions. > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:wix-users- > [EMAIL PROTECTED] On Behalf Of Wilson, Phil > Sent: Monday, October 16, 2006 11:05 AM > To: wix-users@lists.sourceforge.net > Subject: Re: [WiX-users] Uninstall Custom action > > REMOVE="ALL" is the right syntax. Must be time for a log: > > Msiexec /x {your productcode guid} /l*v somepathtoalog.log > > > Phil Wilson > > > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Dane > Anderson > Sent: Monday, October 16, 2006 10:53 AM > To: wix-users@lists.sourceforge.net > Subject: Re: [WiX-users] Uninstall Custom action > > No soap. I tried: > <Custom Action="DeleteCabs" Sequence="3490">Remove="ALL"</Custom> > and > <Custom Action="DeleteCabs" Sequence="3490">REMOVE="ALL"</Custom> > and > <Custom Action="DeleteCabs" Sequence="3490">REMOVE="all"</Custom> > and > <Custom Action="DeleteCabs" Sequence="3490">Remove="all"</Custom> > and > <Custom Action="DeleteCabs" Sequence="3490">REMOVE="All"</Custom> > and > <Custom Action="DeleteCabs" Sequence="3490">Remove="All"</Custom> > > With all I got the same results. It doesn't execute the DeleteCabs > CustomAction. > > > -----Original Message----- > > From: Wilson, Phil [mailto:[EMAIL PROTECTED] > > Sent: Monday, October 16, 2006 10:18 AM > > To: Dane Anderson; wix-users@lists.sourceforge.net > > Subject: RE: [WiX-users] Uninstall Custom action > > > > Properties are case-sensitive in that syntax you're using. Try "ALL". > > > > Phil Wilson > > > > > > -----Original Message----- > > From: [EMAIL PROTECTED] > > [mailto:[EMAIL PROTECTED] On Behalf Of Dane > > Anderson > > Sent: Monday, October 16, 2006 9:28 AM > > To: wix-users@lists.sourceforge.net > > Subject: Re: [WiX-users] Uninstall Custom action > > > > I'm sorry to be a pest, but could you elaborate. I've tried adding - > > REMOVE="All" > > Everywhere I thought it MIGHT belong. In most places it won't even > > compile. In the ONE place it does compile - <Custom > Action="DeleteCabs" > > Sequence="3490">REMOVE="All"</Custom> > > (note: replaced the 'Installed' with 'REMOVE="All"') it does nothing. > In > > other words the custom action doesn't get executed. > > > > > -----Original Message----- > > > From: [EMAIL PROTECTED] [mailto:wix-users- > > > [EMAIL PROTECTED] On Behalf Of Rob Hamflett > > > Sent: Monday, October 16, 2006 1:12 AM > > > To: wix-users@lists.sourceforge.net > > > Subject: Re: [WiX-users] Uninstall Custom action > > > > > > A condition of REMOVE="ALL" should be fine for uninstall CAs. > > > > > > Rob > > > > > > Dane Anderson wrote: > > > > I have an install package that I am attempting to put together. In > > the > > > > process of installing > > > > > > > > I have it run an executable, CabInstaller.exe, that installs the > dll > > > > > > contained in the .cab > > > > > > > > and sets some registry entries (explicitly). Some OTHER registry > > entries > > > > are set > > > > > > > > automagically (and in a completely blackbox way) by some 3^rd > party > > > > executables > > > > > > > > that CabInstaller calls during it's execution. . After being > > executed > > > > CabInstaller.exe is > > > > > > > > deleted from the target machine. I have this much working > perfectly > > > > > > > > The problem I am encountering is, during an uninstall (msiexec /x > > ...) I > > > > need the installer > > > > > > > > to execute CabInstaller with an UNinstall option (CabInstaller > > > > <cabfilename> to install > > > > > > > > and CabInstaller -u <cabfilename> to uninstall). So that it can > call > > > > > > those 3^rd party > > > > > > > > executables with THEIR uninstall options. The target is to produce > > ONE > > > > install > > > > > > > > package that can be used to install or uninstall. HOW do I get the > > FOOL > > > > installer > > > > > > > > to execute a custom action ONLY when uninstalling. My wxs file > has: > > > > > > > > <Directory Id="TARGETDIR" Name="SourceDir"> > > > > > > > > <Directory Id="TempFolder" Name="TempDir"> > > > > > > > > <Component Id="INTAVADLLS" DiskId="1" > > Guid="$(env.INTAVADLSGUID)"> > > > > > > > > <File Id="IntavaDL.cab" Name="IntavaDL.cab" > > > > src="C:\intava\source\Intavadl\IntavaDL.cab" Vital="yes" /> > > > > > > > > <File Id="CabInstaller.exe" Name="INSTALLR.EXE" > > > > LongName="CabInstaller.exe" > > > > > > > > > > > > src="C:\Intava\Source\tools\CabInstaller\Debug\CabInstaller.exe" > > > > Vital="yes" /> > > > > > > > > <File Id="CabUninstallerInstall.bat" Name="CabIns.bat" > > > > LongName="CabUninstallerInstall.bat" > > > > > > > > > > src="C:\trials\SprintKioskSetup\CabUninstallerUninstall.bat" > > > > Vital="yes" /> > > > > > > > > <File Id="CabUninstallerUninstall.bat" Name="CabUnins.bat" > > > > LongName="CabUninstallerUninstall.bat" > > > > > > > > > > src="C:\trials\SprintKioskSetup\CabUninstallerUninstall.bat" > > > > Vital="yes" /> > > > > > > > > > > > > <!-- For the install action --> > > > > > > > > <CustomAction Id="InstallIntavaDl.Dll" > > FileKey="CabInstaller.exe" > > > > ExeCommand="[TempFolder]IntavaDL.cab" > > > > > > > > Return="check" /> > > > > > > > > <!-- For the uninstall action --> > > > > > > > > <CustomAction Id="DeleteCabs" > > FileKey="CabUninstallerUninstall.bat" > > > > ExeCommand="" Return="check" /> > > > > > > > > <!-- CabUninstallerUninstall.bat wraps "%temp%\CabInstaller -u > > > > %temp%\IntavaDL.cab" because for > > > > > > > > some unknown reason CabInstaller throws an exception when doing an > > > > > uninstall if it is being run > > > > > > > > directly by msiexec. It does NOT throw when run from the command > > line. - > > > -> > > > > > > > > <InstallExecuteSequence> <!-- I haven't found any > > > > "UninstallExecuteSequence" documented so I presume this > > > > > > > > is the right place to put both --> > > > > > > > > <Custom Action="InstallIntavaDl.Dll" > After="InstallFinalize">NOT > > > > > > Installed</Custom> > > > > > > > > <Custom Action="DeleteCabs" Sequence="3490">Installed</Custom> > > > > > > > > <!-- I've found the hard way, that the CabInstaller must be > run > > > > BEFORE InstallFinalize on an > > > > > > > > uninstall. AFTER InstallFinalize the CabInstaller no > longer > > > > > > exists on the target machine --> > > > > > > > > The problem is, my DeleteCabs CustomAction NEVER gets executed, > > EVER. I > > > > have verified that the bat file > > > > > > > > executes correctly when run manually. Now I need it to be run by > > > > msiexec. I know for a fact that msiexec > > > > > > > > CAN run bat files, because I have another one that deletes the > .cab > > and > > > > .exe files after they've been > > > > > > > > used in the install. That has been verified to work, so I know it > > can be > > > > done. Just HOW to get it to > > > > > > > > run during an uninstall is what I'm beating my head against. > > > > > > > > > > > > If you have any suggestions: Please send me an E-Mail > > > > ([EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>), as I haven't > > noticed > > > > any links to > > > > > > > > join your mail list. > > > > > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------------------------ > > > > > > > > > > > ------------------------------------------------------------------------ > > > - > > > > 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=lnk&kid=120709&bid=263057&dat=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=lnk&kid=120709&bid=263057&dat=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=lnk&kid=120709&bid=263057&dat=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=lnk&kid=120709&bid=263057&dat=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=lnk&kid=120709&bid=263057&dat=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=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users