.Net port of the Wix standard bootstrapper application - wix

We are currently using WiX with the standard bootstrapper application. In the past this has worked well for our needs, however now we would like to add some additional functionality, such as validation of database details entered in the bootstrapper UI.
I know that this would be possible by modifying the standard bootstrapper application, however this requires coding in C which I would like to avoid. (I can write in C, but I'm far more competent and less error prone in .Net)
Is there a .Net port of the standard bootstrapper application so that we can implement these actions in .Net code, or would I need to write a .Net bootstrapper from scratch?

No, WixStandardBootstrapperApplication is only available in native code. The BA for WiX itself is open source like the rest of WiX: https://github.com/wixtoolset/wix3/tree/develop/src/Setup/WixBA

Related

WIX Toolset I want the ActionData log to continue to be written as a scroll

If you add ActionData to the Subscribe event in Edit Control on Wix,
the line is written and erased. I want the ActionData log to continue to be written as a scroll.
Burn: WiX Burn allows you to write your own GUI to run your installer. You should be able to implement whatever you want in terms of GUI if you go down that path. However: installers run quicker and quicker as IO becomes better, are you sure this is time well spent? I'd say just use logging and be done with it? See my comments above for your question.
Burn Bootstrapper Appliation: There are not that many samples I know about for Custom WiX Burn Bootstrapper applications. Here are two:
Write your own WiX Burn setup GUI application (advanced)
https://github.com/rstropek/Samples/tree/master/WiXSamples/CustomBurnUI
Documentation: For documentation go online, or better yet open WiX.chm and locate section "Building Installation Package Bundles".
Here are two past answers that I would suggest you at least skim:
Ways to customize your WiX GUI (do read this one for overall understanding of MSI GUI)
Custom GUI - WiX Burn, Installshield Suite Project, Advanced Installer - their options
The Implementation of a custom GUI for an MSI depends on the core MSI API function MsiSetExternalUI function. It allows what Burn is doing - making a custom GUI. Throwing in an SDK sample too:
MSI SDK Sample: Some details on the MsiSetExternalUI function (serverfault answer). Concrete code sample to handle Windows Installer messages: https://learn.microsoft.com/en-us/windows/desktop/Msi/handling-progress-messages-using-msisetexternalui. This is MSI API calls direct - nothing to do with Burn as such, Burn makes use of these calls.
Links: Link overload - as usual - but here is an example of a custom Burn theme - as opposed to a custom bootstrapper application. This changes the look of the standard Burn bundle.
https://github.com/frederiksen/Classic-WiX-Burn-Theme
SQL Server named instance with Visual Studio 2017 Installer project (just for inclusion)
Native Windows Installer UI doesn't support this. You would need to create a custom UI handler to display it the way you want.

WixManagedBootstrapperApplicationHost custom UI

I have created a msi which allows user to view license, select installation folder, and features to install. That all works well.
Now I need to create a bootstrapper that will check if framework 4.5 is installed, install it if not, and then install msi.
I can do this using WixStandardBootstrapperApplication.RtfLargeLicense, where I would install framework, and then execute msi with its own UI.
But what if I do not want to show two apps (msi over exe), but only one window?
Since my msi contains feature, standard bootstrapper does not provide interface where I can set features from msi, so I need to create a custom UI.
The problem is I do not quite understand how WixManagedBootstrapperApplicationHost works? I created a dll with new UI, and place it in Payload. When running the setup, when framework needs to be installed, WixManagedBootstrapperApplicationHost always invokes its own window which says:
Microsoft .NET Framework required for MyApp Setup. Click the "Accept and Install" button to accept the Microsoft .NET Framework license terms.
And after it completes installation of .NET Framework, then it invokes the UI that I Created in dll. Why would anyone want this kind of functionality, where my bootstrapper app contains totally different UI than the framework installation UI? Isn't the idea of bootstrapper with custom UI is to provide completely custom UI?
So, how can I provide my custom UI for that framework installation part?
I assume your own UI is C# and WPF? If your installing it on a machine without .Net then it's going to need to install .Net before it can show the WPF UI. I could be wrong but I'm sure that's unavoidable.
If you want to replace / modify the .Net install screen then this thread looks like it has the answer:
Wix Burn: Basic UI handling if No Net Framework is there
However if your saying the .Net install dialog is showing up over your UI at some point in installation then you need to set the Install command to "/q" which means quiet (no UI).

Wix 3.6 bootstrapper to just launch msi

I am working with WIX 3.6, it has some great features to create managed bootstrapper application. I have managed to create a WPF ui for that. But, I dont want to create and handle all the events for the installer, our requirement is only to get an initial parameter like language selection from the user and proceed to the MSI. MSI already handles upgrade / uninstall and install checks.
Bootstrapper.Engine.Plan(LaunchAction.Install);
Is it possible to just launch the MSI without specifying the install / uninstall action codes?
Thanks!
Unfortunately, not today. The interface provided today is very powerful and you can control just about everything. That also means that you need to control a lot to get the core scenarios working. As we progress in the WiX toolset, we'll build up additional abstraction layers so that a custom BA is easier to write. The Burn functionality is still rather new and just needs time to have more code contributed.
If you want to look on the bright side, be glad that you'll be able to accomplish just about any required UI task because the interface provided is so expressive. :)

How to make rich GUI design fow WiX(Windows Installer XML) dialog?

I am using WiX for make installer for any product. But I don't want to use default UI dialog which is using in WiX. How to improvise UI of a installer ? Is there any tool for designing UI for a installer with highly customize ?
Rich GUI is done in bootstrapper (aka. chainer). Chainers are made in tool called Burn (B is for bootstrap). I'm not all that familiar with it, but it was supposed to replace all the GUI available by Windows Installer that you can set in .msi files. This GUI is restrictive, and suitable only for simplest tasks, so the idea is to build .msi only as a database file that is to be consumed by Windows Installer to actually install something, and transfer all the GUI to bootstrapper.
The only thing I've come across is WixEdit, although it seems buggy and may have been abandoned. Still, it allows you to do basic UI design of the WiX dialogs.
I recently came across something called Wix#. It lets you make custom dialogs using a Winforms-like designer.
I know it's 9 years later, but if it helps, great.

WiX: Use Burn to install .NET then launch an MSI with its own WPF Embedded UI

I have already made a MSI installer with WiX using a custom WPF UI with the EmbeddedUI element. It is similar to the sample found in src/DTF/Samples/EmbeddedUI.
I would now like to have a bootstrapper that checks if .NET 4 is installed and install it if it's not, and then launch my MSI.
It looks like Burn would override my WPF EmbeddedUI in order to chain the .NET 4 and MSI installations into a single installation with a single progress bar. I know that I could have a managed application to change the UI of Burn then pass parameters to my MSI but the problem is that I would like my UI to be in WPF which relies on .NET, and if the whole bootstrapper relies on .NET then the user couldn't even open the bootstrapper if he doesn't have it installed in the first place.
What I would like is the bootstrapper to install .NET if needed with a simple UI like Wixstdba, and then launch my MSI as it is, with its own WPF EmbeddedUI, without chaining it with the .NET installation. I don't mind that both installations would have their own progress bar, I would just like to be able to use my WPF EmbeddedUI for the installation of the main application.
Would that be possible. How? Thanks!
If you want your WiX bootstrapper to display the UI of your installer, set the DisplayInternalUI attrible of the MsiPackage to true. That solution does have the downside of displaying two UIs during install though.
You can also create a managed bootstrapper application using WPF and .NET. Burn provides a way to basically bootstrap itself and install .NET before displaying your custom UI.