wix3.9 - Editing packaged file in WiX -


wix newbie here. i'm curious if approach possible using wix.

problem statement...

i packaging sql files want execute against parameters user enter @ run time. think connection string information. 1 of parameters user can enter directory want db installed.

current solution (doesn't work).....

to i'm packaging these files using heat. when sucks in files 1 of sql files has tokens in them custom action looks find replace in file. problem thatwhile indeed doing find replace it's doing them against source files heat sucked in , not files exist in .msi file.

question 1...

within wix workflow there way via custom action can processing on files stored within .cab or .msi file? if possible can show me example of this?

question 2 . . .

if question 1 isn't possible other idea had break find replace sql piece , file install piece separate msi file. first step explode files need install directory via 1 msi. next msi execute sql piece @ point files exist on file system me editing on. sound sane approach problem? i'm trying work around wix , not wix here.

current code snippets

<product>    <!-- installed-->     <directory id="targetdir" name="sourcedir">         <directory id="installfolder" name="zolldata">             <directory id="sqlinstallfolder" name="sql" />         </directory>     </directory>      <!-- custom action definitions-->     <customaction id="findreplacezedstextca"                   return="check"                   binarykey="gemstoneinpremiseinstallercustomactions.ca.dll"                   execute="immediate"                   dllentry="findreplacetext" />        <!-- database information-->     <util:user id="sqluser" name="[sqlusername]" password="[sqlpassword]"/>     <sql:sqldatabase id="masterdatabase" database="master"                         server="[sqlservername]"                         user="sqluser"/>       <installuisequence>         <show dialog="sqlconnectiondlg" after="costfinalize" />         <show dialog="progressdlgcustom" after="sqlconnectiondlg"/>     </installuisequence>      <installexecutesequence>         <custom action="findreplacezedstextca" after="installfiles">         </custom>     </installexecutesequence> </product>  <fragment>         <directoryref id="installfolder" />     </fragment>     <fragment>         <componentgroup id="sqlcomponents">             <component id="createdatabase.sql" directory="installfolder" guid="6a2c6088-9302-451c-a01b-02d618d4ac27">             </component>         </componentgroup>     </fragment> 

thanks in advance.

the problem custom action set execute="immediate". should have been execute="deferred".


Comments

Popular posts from this blog

javascript - jQuery: Add class depending on URL in the best way -

caching - How to check if a url path exists in the service worker cache -

Redirect to a HTTPS version using .htaccess -