I simplified my approach a bit and was able to get the exe to be copied over (along with a few xml files) and run...
However, now I have a problem where I attempt to open the files when running the exe, the current directory is set to c:\. I tried passing in the INSTALLDIR as a parameter to the call, but it is being passed in as the empty string. Below are the relevant snippets, any help would be appreciated. I have tried several flavors of specifying the installdir: INSTALLDIR, [INSTALLDIR], "[INSTALLDIR]" <Component Id="RouteGeneratorComponent" Guid=" 3D12166D-F85B-4f32-8E60-DFD9B8A117DE"> <File Id="RouteGenerator.exe" Source=" $(var.RouteGenerator.TargetDir)RouteGenerator.exe" DiskId="1" Name=" RouteGenerator.exe" Vital="yes" KeyPath="yes" /> <File Id="RoutingData.xml" Source=" $(var.RouteGenerator.TargetDir)RoutingData.xml" DiskId="1" Name=" RoutingData.xml" Vital="yes" /> <File Id="RoutingTopology.xml" Source=" $(var.RouteGenerator.TargetDir)RoutingTopology.xml" DiskId="1" Name=" RoutingTopology.xml" Vital="yes" /> </Component> <Feature Id="ProductFeature" Title="Conversation Db" Level="1"> <ComponentRef Id="RouteGeneratorComponent" /> <ComponentRef Id="FooComponent" /> </Feature> ... <CustomAction Id="RouteGeneratorExe" FileKey="RouteGenerator.exe" ExeCommand ='"[INSTALLDIR]" myParam2 [DBNAME]' Return="asyncNoWait"/> <InstallExecuteSequence> <Custom Action="RouteGeneratorExe" After="InstallFinalize" /> </InstallExecuteSequence> On Mon, Aug 4, 2008 at 1:07 PM, Roberto Almanza <[EMAIL PROTECTED]>wrote: > > Hi. > > I am trying to use a merge module to define an exe that I will then > reference from several wix projects. The merge module definition is below. > > I then make the modificaitons to my wix project as specified below. > > Ultimately I simply want to have the executable copied to the install > direction and run with the given parameters in each of my wix projects. One > parameter being variable and the other always being the DBNAME(which i give > as a command line parm argument). > > I am wondering if I am using merge module correctly? Also wondering if I am > using custom action correctly and if someone could point me to a good > example of doing this or help me repair my error below. I am having a > difficult time going to through the wix documentation to understand the > various Custom Action Types. > > Currently my wix project compiles, however I get the following error when > running the installer: > "This installation package could not be opened. Contact the application > vendor to verify that this is a valid Windows Installer package." > > Thanks. > > > > Wix File Changes: > > ... > > < > Merge Id ="RouteGeneratorModule" Language="1033" SourceFile=' > $(var.RouteGenerator.TargetDir)RouteGenerator.msm' DiskId='1' /> > > </ > Directory> > ... > > > < > CustomAction Id="CA1" Property="MyParam1 [DBNAME]" > > Value="RouteGenerator.exe" /> > > > > < > InstallExecuteSequence> > > < > Custom Action="CA1" After="InstallFinalize" /> > > </ > InstallExecuteSequence> > > > > < > Feature Id="ProductFeature" Title="Foo" Level="1"> > > < > MergeRef Id="RouteGeneratorModule" /> > > < > ComponentRef Id="FooId" /> > > </ > Feature> > > ... > > > Merge Module: > > <? > xml version="1.0" encoding="UTF-8"?> > > < > Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"> > > < > Module Id="RouteGenerator" Language="1033" Version="1.0.0.0"> > > < > Package Id="bbd7e4db-dd7a-45b8-a9e9-78de83856d73" Manufacturer=" > RouteGenerator" InstallerVersion="200" /> > > < > Directory Id="TARGETDIR" Name="SourceDir"> > > < > Directory Id="MergeRedirectFolder"> > > < > Component Id="ModuleComponent" Guid="3D12166D-F85B-4f32-8E60-DFD9B8A117DE"> > > > < > File Id="RouteGenerator" Source=" > $(var.RouteGenerator.TargetDir)RouteGenerator.exe" /> > > </ > Component> > > </ > Directory> > > </ > Directory> > > </ > Module> > > </ > Wix> > > ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users