4

I just started working on an installer my company is creating and we are using WiX. During installation, we ask for the installer's name and email address. The "Next" button is disabled until both of those fields are no longer empty. However, the button doesn't become enabled until focus is changed from the last field edited. I would like to enable the button as soon as both fields have something in them. Here's what I've got so far:

<Control Id="Next" Type="PushButton" X="236" Y="243" Width="56" Height="17" Default="yes" Text="!(loc.WixUINext)">
    <Condition Action="disable"><![CDATA[UNAME = "" OR EMAIL = ""]]></Condition>
    <Condition Action="enable"><![CDATA[UNAME <> "" AND EMAIL <> ""]]></Condition>
</Control>

Any and all help will be greatly appreciated. Thank you.

1 Answer 1

7

This is not supported by Windows Installer. Control conditions are not evaluated as you type in an edit box.

A solution would be a dummy Validate button next to your edit box. The user can click it after typing in the edit box so the focus is changed and control conditions evaluated.

Another solution would be to use an external UI which evaluates control conditions as you type. Some commercial setup authoring tools have this feature built-in.

2
  • 2
    That being the case, I'm thinking of leaving the "Next" button enabled, and running a Custom Action when the button is clicked to verify information is in the text boxes. Would this be a more feasible action? Thanks!
    – PiousVenom
    Nov 17, 2011 at 16:58
  • 1
    Thanks for your help. I'd upvote the answer, but I lack the reputation.
    – PiousVenom
    Nov 17, 2011 at 19:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.