I'm pretty sure there is something wrong here, but I don't know what it is.

I'm using WiX 3.5, and I'm using the (project name).Generated.wxs files that
Visual Studio generates when you add references to them in the wix project.

When I build the service it includes all the files as I wanted, but since
the generated wxs file doesn't have keypath listed on any file, the service
that is installed has some wacky incorrect path.  It's the name of the
project instead of an actual path to a file.

Any ideas how to specify one of the files in the generated wxs as the
keypath?  I would appreciate some guidance as I'm stuck here.

Thanks!
Brendan

Here is my wix file, what

<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi";>
    <Product Id="A-VALID-GUID" Name="ServiceName" Language="1033"
Version="1.0.0.0" Manufacturer="Me" UpgradeCode="ANOTHER-VALID-GUID">
        <Package InstallerVersion="200" Compressed="yes" />

        <Media Id="1" Cabinet="ServiceName.cab" EmbedCab="yes" />

    <UIRef Id="WixUI_Common" />
    <UI>
      <Property Id="DefaultUIFont" Value="WixUI_Font_Normal" />
      <TextStyle Id="WixUI_Font_Normal" FaceName="Tahoma" Size="8" />
      <TextStyle Id="WixUI_Font_Bigger" FaceName="Tahoma" Size="12" />
      <TextStyle Id="WixUI_Font_Title" FaceName="Tahoma" Size="9" Bold="yes"
/>

      <Property Id="WIXUI_INSTALLDIR" Value="INSTALLLOCATION" />
      <Property Id="ARPNOMODIFY" Value="0" />
      <Property Id="WixUILicenseRtf" Value="ServiceName.rtf" />

      <DialogRef Id="BrowseDlg" />
      <DialogRef Id="DiskCostDlg" />
      <DialogRef Id="ErrorDlg" />
      <DialogRef Id="FatalError" />
      <DialogRef Id="FilesInUse" />
      <DialogRef Id="MsiRMFilesInUse" />
      <DialogRef Id="PrepareDlg" />
      <DialogRef Id="ProgressDlg" />
      <DialogRef Id="ResumeDlg" />
      <DialogRef Id="UserExit" />

      <Publish Dialog="ExitDialog" Control="Finish" Event="EndDialog"
Value="Return" Order="999">1</Publish>
      <Publish Dialog="WelcomeDlg" Control="Next" Event="NewDialog"
Value="LicenseAgreementDlg">1</Publish>

      <Publish Dialog="LicenseAgreementDlg" Control="Back" Event="NewDialog"
Value="WelcomeDlg">1</Publish>
      <Publish Dialog="LicenseAgreementDlg" Control="Next" Event="NewDialog"
Value="InstallDirDlg">LicenseAccepted = "1"</Publish>

      <Publish Dialog="InstallDirDlg" Control="Back" Event="NewDialog"
Value="LicenseAgreementDlg">1</Publish>
      <Publish Dialog="InstallDirDlg" Control="Next" Event="SetTargetPath"
Value="[WIXUI_INSTALLDIR]" Order="1">1</Publish>
      <Publish Dialog="InstallDirDlg" Control="Next" Event="NewDialog"
Value="ServiceCredentialsDlg" Order="2">1</Publish>
      <Publish Dialog="InstallDirDlg" Control="ChangeFolder"
Property="_BrowseProperty" Value="[WIXUI_INSTALLDIR]" Order="1">1</Publish>
      <Publish Dialog="InstallDirDlg" Control="ChangeFolder"
Event="SpawnDialog" Value="BrowseDlg" Order="2">1</Publish>

      <Publish Dialog="VerifyReadyDlg" Control="Back" Event="NewDialog"
Value="ServiceCredentialsDlg" Order="1">NOT Installed</Publish>
      <Publish Dialog="VerifyReadyDlg" Control="Back" Event="NewDialog"
Value="MaintenanceTypeDlg" Order="2">Installed</Publish>

      <Publish Dialog="MaintenanceWelcomeDlg" Control="Next"
Event="NewDialog" Value="MaintenanceTypeDlg">1</Publish>
      <Publish Dialog="MaintenanceTypeDlg" Control="RepairButton"
Event="NewDialog" Value="VerifyReadyDlg">1</Publish>
      <Publish Dialog="MaintenanceTypeDlg" Control="RemoveButton"
Event="NewDialog" Value="VerifyReadyDlg">1</Publish>
      <Publish Dialog="MaintenanceTypeDlg" Control="Back" Event="NewDialog"
Value="MaintenanceWelcomeDlg">1</Publish>
    </UI>

    <Directory Id="TARGETDIR" Name="SourceDir">
        <Directory Id="ProgramFilesFolder">
        <Directory Id="CompanyName" Name="Company">
          <Directory Id="INSTALLLOCATION" Name="Service Name">
            <Component Id="ProductComponent" Guid="ANOTHER-VALID-GUID">
              <File Id="ANeededFile" Name="somefile.dll"
Source="${var.ServiceName.TargetDir)\somefile.dll" />
              <ServiceInstall Id="ServiceInstall"
                              Name="ServiceName"
                              DisplayName="Service Name"
                              Type="ownProcess"
                              Start="auto"
                              ErrorControl="normal"
                              Description="This service performs some task."
                              Vital="yes"
                              Account="[ACCOUNT]"
                              Password="[PASSWORD]"/>
              <ServiceControl Id="StartService" Name="Service Name"
Start="install" Wait="no"/>
              <ServiceControl Id="StopService" Name="Service Name"
Stop="both" Wait="yes" Remove="uninstall" />
            </Component>
          </Directory>
                </Directory>
            </Directory>
        </Directory>

        <Feature Id="ProductFeature" Title="Service Name" Description="This
service does something." Level="1">
            <ComponentRef Id="ProductComponent" />

            <!-- Note: The following ComponentGroupRef is required to pull
in generated authoring from project references. -->
            <ComponentGroupRef Id="ServiceName.Generated" />
        </Feature>
    </Product>
</Wix>
------------------------------------------------------------------------------
Sell apps to millions through the Intel(R) Atom(Tm) Developer Program
Be part of this innovative community and reach millions of netbook users 
worldwide. Take advantage of special opportunities to increase revenue and 
speed time-to-market. Join now, and jumpstart your future.
http://p.sf.net/sfu/intel-atom-d2d
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to