I'm following this extract from wixtoolset.org - Changing the WiX Standard Bootstrapper Application Branding as I'm using the HyperlinkSidebarLicense UI.
<?xml version="1.0"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:bal="http://schemas.microsoft.com/wix/BalExtension">
<Bundle>
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.HyperlinkSidebarLicense">
<bal:WixStandardBootstrapperApplication
LicenseUrl="License.htm"
LogoFile="path\to\customlogo.png" LogoSideFile="path\to\customsidelogo.png"
/>
</BootstrapperApplicationRef>
<Chain>
...
</Chain>
</Bundle>
</Wix>
However, I can't seem to find any reference to what size the PNG files need to be.
Has anyone worked with the bootstrapper before who can advise here?
According to the images included in the source, it looks like...
LogoFile is 64x64
LogoSideFile is 165x400
The size of these can be found in the corresponding wix theme files:
- RtfTheme.xml
- HyperlinkLicenseTheme.xml
- FoundationTheme.xml
depending on which one you are using, I'm not sure if they vary per theme but that is where the sizes are located.
Note (I believe this is a bug but I'm not sure): If you try to copy the themes into your own theme and modify theme image names at all, the wix solution will not start.
Using the properties in the WixStandardBootstrapperApplication, We also have another solution that uses a 64x64 for LogoFile but a 128x128 LogoSideFile. So once again I'm left slightly confused about WiX.
Your mileage may vary.
Related
I've discovered how to access the parts within the MSI/Product tag. But my goal was to set the caption of the burn installer based on the Major/Minor version number.
This code below is the summary of what I tried to do, but this doesn't work (I think because I'm not within the Product tag).
Burn wxs:
<Wix>
<Bundle Version="!(bind.packageVersion.<packageName>)" >
<Variable Name="ProductVersionMajor" Value="!(bind.property.ProductVersion.Major)"/>
<Variable Name="ProductVersionMinor" Value="!(bind.property.ProductVersion.Minor)"/>
....
Theme.wxl:
<WixLocalization ...>
<String Id="Caption">[WixBundleName] [ProductVersionMajor].[ProductVersionMinor] Setup</String>
....
Is there some kind of work around where I can get this information at the bundle level without writing custom code?
This answer here was useful, but not quite what it appears I need; since I'm not within the WIX product tag for the inner MSI.
!(bind.property.ProductVersion.Major) is a bind variable when building an MSI, not a bundle. The available bind variables are documented at https://wixtoolset.org/documentation/manual/v3/overview/light.html. There is an open feature request for MsiPackage property bind variables at https://github.com/wixtoolset/issues/issues/4298. It would likely be additional work to get the ProductVersion.Whatever part working, so if you want that then you should add a comment to that issue.
In addition to #Sean's answer, if you are only interested in the full version and not in any breakdown of major/minor/build then the below example I have the caption in the localization WXL file can be defined as simple as:
<WixLocalization Culture="en-us" Language="1033" xmlns="http://schemas.microsoft.com/wix/2006/localization">
<String Id="Caption">[WixBundleName] Setup (v. [WixBundleVersion])</String>
...
and in my bundle.wxs file I have the following definition:
<Bundle Name="$(var.MyProductFullName)"
Version="!(bind.packageVersion.MyPackageId)"
Manufacturer="!(bind.packageManufacturer.MyPackageId)">
...
where the variable MyProductFullName is defined in my variables file under my package's installer project. So basically the [WixBundleName]
and [WixBundleVersion] are bound to the Bundle element's Name and Version attribute values, respectively.
In my bootstrapper Theme.xml I want to reference a path variable from a .wxs file.
In Bundle.wxs I reference certain variables using the $() syntax.
In my <BootstrapperApplicationRef> I use a ThemeFile.
From there I want to use the same variables (for example var.BundelVersionNumber). How can I achieve that?
Bundlex.wxs
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:bal="http://schemas.microsoft.com/wix/BalExtension"
xmlns:util="http://schemas.microsoft.com/wix/UtilExtension">
<Bundle Name="MyApplication $(var.BundelVersionNumber) ($(var.Platform))"
I see that I can use some built-in burn variables, for example [WixBundleName ],:
http://wixtoolset.org/documentation/manual/v3/bundle/bundle_built_in_variables.html
You can declare a variable in your bundle and define the value based on a preprocessor variable.
<Variable Name="Platform" Value="$(var.Platform)"/>
Then you can use it in your theme.xml (or preferably your localized theme wxl ).
[Platform]
In the Wix wizard there's a red CD icon here:
and here:
How do you change it?
I tried adding:
<WixVariable Id="WixUIInfoIco" Value="Dashman-setup-icon.bmp" />
<WixVariable Id="WixUIExclamationIco" Value="Dashman-setup-icon.bmp" />
but it had no effect.
The red CD icons are part of the bitmaps used in the WixUIExtension. In the source code for WixUIExtension, you can view the bitmaps it uses. From UI Wizardy:
<!-- WixUIBannerBmp 493 by 58 pixels,
this bitmap will appear at the top of all
but the first page of the installer-->
<WixVariable Id="WixUIBannerBmp" Value="path\banner.bmp" />
<!-- WixUIDialogBmp 493 by 312 pixels,
this bitmap will appear on
the first page of the installer.-->
<WixVariable Id="WixUIDialogBmp" Value="path\dialog.bmp" />
IsWiX has project templates that pick up where the rather terse project templates from WiX leave off. Out of the box you get a Code and Resources folder and a series of WiX fragments that define standard things such as MajorUpgrades, common AppSearch/LaunchConditions and pulling in WiXUI with allowances for easily injecting a custom dialog by simply uncommenting out a line of XML.
https://github.com/iswix-llc/iswix/tree/main/Application/IsWiX2022AddIn/VotiveMSISolutionTemplate/SetupProjectTemplate
As the project coordinator I might be biased, but I just finished doing a bunch of UI work that previously I would have only dared doing in InstallShield.
I want to use different icons for my setup.exe (top-leftmost corner of the installer window) and Add/Remove Programs. In my Bundle.wxs, I used <Bundle ... IconSourceFile='path\to\product1.ico'> but when I set the value there it is applying to both places as described in its documentation. So I tried this in my Product.wxs <Icon Id="ProductIcon" SourceFile="path\to\product2.ico"/> <Property Id='ARPPRODUCTICON' Value='ProductIcon'/> in an attempt to override the declaration in Bundle, but it still shows the first icon in Add/Remove programs. Any help? Thanks!
I faced the same problem. The solution is to change Logo attribute of custom BA main window.
I'm new to WiX, and using WiX v3.0.
I'm using the WixUI_Advanced dialogs. I customized InstallDirDlg description by adding a .wxl (WiX localization) file.
However, I cannot add a newline in the description.
I tried following to get a new line,
1. <String Id="InstallDirDlgDescription">Hello\nHai</String>
2. <String Id="InstallDirDlgDescription">Hello
Hai</String>
3. <String Id="InstallDirDlgDescription">Hello</String>
<String Id="InstallDirDlgDescription" Overridable="yes">Hai</String>
4. <String Id="InstallDirDlgDescription">Hello
Hai</String>
But, none of those options work. Any suggestions.
It appears you've found a bug in the .wxl handling in the WiX toolset. I would expect option number 4 or the following to work:
<String Id="InstallDirDlgDescription"><![CDATA[Hello
Hai]]></String>
At this point, you'll probably be best served opening a WiX toolset bug. You might even consider enlisting in the code and trying to root cause the issue to help get the bug fixed. Seems like it should work.