How to enable/disable NEXT button on textbox keypress event in msi installer with wix RRS feed

  • Question

  • I have a dialog which has two edit boxes. One for username(USERNAME) and the other for the password(PASSWORD). I am doing a small validation like "Next" button will be disabled until the user types something in the username  password edit text box and my wix code snippet is written below:-

    Wix code :-

    <Control Id="UserNameLabel" Type="Text" X=.... Text=" User Name:" />
    <Control Id="UserNameEdit" Type="Edit" X=..Property="NAME" Text="{80}" />
    <Control Id="PasswordLabel" Type="Text" X......... Text=" Password:" />
    <Control Id="PasswordEdit" Type="Edit" X="...Property="PASSWORD" Password="yes" Text="{80}" />
     <Control Id="Back" Type="PushButton" X="....." Text="&amp;Back"> </Control>
    <Control Id="Next" Type="PushButton" X="... Default="yes" Text="&amp;Next">
                <Condition Action="enable" ><![CDATA[IP AND NAME AND  PASS]]></Condition>
                <Condition Action="disable"><![CDATA[NOT IP OR NOT NAME OR NOT PASS]]></Condition>
    <Control Id="Cancel" Type="PushButton" X=... Text="Cancel">
                  <Publish Event="SpawnDialog" Value="CancelDlg">1</Publish>

    However, the above code does not work for the keypress event, it works only when I move out of password edit box (e.g. When I type something in the password edit box, "Next" button does not get enabled. It gets enabled when the focus is moved out of the password edit box).

    Is it possible to enable the "Next" as soon as user types something in the password edit box like Password: is "test123" & as user type password "te" only so "Next" button enable automatically.

    Wednesday, May 7, 2014 4:37 PM