how to disable back button in setup build using wixtoolset on VerifyReadyDlg

Viewed 52

I am making a customize setup using wixtoolset v 3.11

On the custom diaglog CustomDlgOTP the next button pass to VerifyReadyDlg

<Control Id="Next" Type="PushButton" Text="&amp;Next" TabSkip="no" Default="yes" Height="17" Width="56" X="236" Y="243">
<Publish Event="NewDialog" Value="VerifyReadyDlg"><![CDATA[propertyreturncode = "200"]]></Publish>
</Control>
<!-- <Publish Dialog="VerifyReadyDlg" Control="Back" Event="NewDialog" Value="CustomDlgOTP" Order="1"> NOT Installed </Publish> --> 

I want user should not be able to hit back button from VerifyReadyDlg. I tried commenting but the button is still visible but with no action. Need a way to disable the back button on VerifyReadyDlg

1 Answers

You disabled action bounded to that button, but didn't disable the button itself. You should rewrite VerifyReadyDlg, remove back button from it, and then add edited dialog to your UI instead of original one.

  1. In Wix source code find file VerifyReadyDlg.wxs. Copy it to your project. In copied file rename Dialog Id="VerifyReadyDlg" to Dialog Id="MyVerifyReadyDlg"
  2. In copied file delete/comment Control Id="Back" element.
  3. In your UI (which you presented in question) add element <DialogRef Id="MyVerifyReadyDlg" />
  4. In your UI replace all occurrences of VerifyReadyDlg to MyVerifyReadyDlg (commented part should stay commented)
Related