True. The custom action uses: TempDir = session.GetTargetPath("TempFolder"); According to the msiexec-log: MSI (c) (70:88) [14:19:49:505]: Dir (target): Key: TempFolder , Object: C:\Users\Tom\AppData\Local\Temp\ And according to my log-messages from within the custom action that does GetTargetPath: MYDBLOG - Begin read parameter 'TempFolder' MYDBLOG - End read parameter 'TempFolder' with value 'C:\Users\Tom\AppData\Local\Temp\' That's why I was thinking the problem is the file isn't written to the Temp-folder. Regarding the order of things, I was thinking these custom actions, albeit after the directory-declarations, were run before the file is written to Temp. Which may very well be the case as I'm not very gracefully finding my way through the pitfalls. Directly after the feature-tag that includes the component/file, I've got the installsequence: <InstallExecuteSequence> <Custom Action="installTpdb" Before="tryUpdateTpdb">NOT Installed</Custom> <Custom Action="tryUpdateTpdb" Before="tryReadTpdb">NOT Installed</Custom> <Custom Action="tryReadTpdb" Before="InstallFinalize">NOT Installed</Custom> <Custom Action='uninstallTpdb' After='InstallFinalize'>(NOT UPGRADINGPRODUCTCODE) AND (REMOVE="ALL")</Custom> </InstallExecuteSequence>
<!-- BEGIN: Add/Remove Programs Icon --> <Property Id="ARPPRODUCTICON" Value="appicon.ico" /> <!-- BEGIN: User Interface --> <UIRef Id="WixUI_my_UI" /> </Product> </Wix> Cheers, Tom > From: pally.sand...@iesve.com > To: wix-users@lists.sourceforge.net > Date: Tue, 28 May 2013 13:21:00 +0000 > Subject: Re: [WiX-users] Putting File in TempFolder - Nothing Happens > > Which Temp directory are you looking in? > The TempFolder property page on MSDN says Windows Installer uses the > GetTempPath function to retrieve the path > ->http://msdn.microsoft.com/en-us/library/aa372067.aspx > GetTempPath retrieves the first valid path stored in certain environment > variables in the order TMP, TEMP & USERPROFILE -> > http://msdn.microsoft.com/en-us/library/aa364992.aspx > Your custom action should be calling GetTempPath to ensure it gets the same > path as the TempFolder property. > > You haven't pasted the WiX for your Custom Action. When is it being called? > > Palbinder Sandher > Software Platform Engineer > T: > +44 (0) 141 945 8500 > F: > +44 (0) 141 945 8501 > http://www.iesve.com > > **Design, Simulate + Innovate with the <Virtual Environment>** > Integrated Environmental Solutions Limited. Registered in Scotland No. > SC151456 > Registered Office - Helix Building, West Of Scotland Science Park, Glasgow > G20 0SP > Email Disclaimer > > > -----Original Message----- > From: Tom - [mailto:mittegetm...@hotmail.com] > Sent: 28 May 2013 13:33 > To: wix-users@lists.sourceforge.net > Subject: [WiX-users] Putting File in TempFolder - Nothing Happens > > Good afternoon, > > I am creating a database installation. First I try to migrate a database from > SQL 2005 to SQL 2008, but should no database be on a SQL 2005 on the machine, > I am installing a new one. To make this happen, I thought I'll put a backup > file into the TempFolder and reference that file in my custom action to > restore it. So far so good but it's not working. It's not working because it > can't find the backup-file in the TempFolder. The XML that I've got is: > > <Directory Id="TARGETDIR" Name="SourceDir"> > <Directory Id="TempFolder"> > <Component Id="DatabaseBackupFile" Guid="*"> > <File Id='FileBackupFile' DiskId='1' > Source='SetupContent\db-package.bak' KeyPath='yes' /> > </Component> > </Directory> > <Directory Id="ProgramFilesFolder"> > <Directory Id="CompanyFolder" Name="CompanyName"> > <Directory Id="INSTALLDIRECTORY" Name="DB WiXTest"> > </Directory> > </Directory> > </Directory> > </Directory> > > <!-- BEGIN: Features --> > <Feature Id="ProductFeature" ConfigurableDirectory="TARGETDIR" Level="1"> > <ComponentRef Id="DatabaseBackupFile" /> > </Feature> > > Either that XML is messed up, or my custom action runs before the file has > been placed in the TempFolder. Reading the logs or looking in the folders, I > can't figure out which. Anyone spot anything wrong in the above, or know what > I can to to fix this? > > Cheers, > > Tom > > ------------------------------------------------------------------------------ > Try New Relic Now & We'll Send You this Cool Shirt New Relic is the only > SaaS-based application performance monitoring service that delivers powerful > full stack analytics. Optimize and monitor your browser, app, & servers with > just a few lines of code. Try New Relic and get this awesome Nerd Life shirt! > http://p.sf.net/sfu/newrelic_d2d_may > _______________________________________________ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users > > > > ------------------------------------------------------------------------------ > Try New Relic Now & We'll Send You this Cool Shirt > New Relic is the only SaaS-based application performance monitoring service > that delivers powerful full stack analytics. Optimize and monitor your > browser, app, & servers with just a few lines of code. Try New Relic > and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may > _______________________________________________ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------------ Try New Relic Now & We'll Send You this Cool Shirt New Relic is the only SaaS-based application performance monitoring service that delivers powerful full stack analytics. Optimize and monitor your browser, app, & servers with just a few lines of code. Try New Relic and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users