tags:

views:

100

answers:

2

I'm trying to customise the standard WiX Progress Dialog (I want to make it show the ActionData). I've followed Neil's guide to customising dialogs but the trouble is, the original ProgressDlg is still being shown instead of mine.

I think I know why: if you tool at the source to ProgressDlg you can see this block of code:

   <InstallUISequence>
    <Show Dialog="ProgressDlg" Before="ExecuteAction" />
  </InstallUISequence>

So rather than being published by another dialog, as most dialogs are, it is being triggered directly as part of the InstallUISequence. So how do I override this?

A: 

It seems that the progress dialog must be the last thing in the InstallUISequence before ExecuteAction - otherwise, because Progress Dialogs are modeless, it is shown then hidden straight away.

My solution therefore is just to make sure that my custom progress dialog is shown after the existing one:

  <InstallUISequence>
    <Show Dialog="CustomProgressDlg" After="ProgressDlg" />
  </InstallUISequence>
Samuel Jack
A: 

ProgressDlg is scheduled only when you refer to it. If you want to replace it, customize your dialog sequence to not refer to ProgressDlg.

Bob Arnson
@Bob, isn't it the case that, because the WiX UI Extensions include a reference to ProgressDlg in the InstallUISequence (as I showed in my question) the only way I could avoid referencing it is to not use the UI Extensions?
Samuel Jack
As Neil's blog post shows, you create a new fragment that has its own DialogRef to ProgressDlg; just replace it in your custom fragment. As long as you don't reference ProgressDlg, its InstallUISequence scheduling won't be included.
Bob Arnson
@Bob, you've described the way I thought it should work: I've cloned WixUI_Adv and removed all DialogRef's to ProgressDlg. I've done a search in my project to check there are no other references to ProgressDlg - but still it ends up in my MSI :-(. Any chance that this might be a bug in Wix (I'm using 3.5.1804)?
Samuel Jack