locked
How to make Edit1Value Mandatory Field in Textboxes Dialog RRS feed

  • Question


  • Hi,

    I've recently created a setup project for my C# .net windows application.

    In my User Interface Editor I have:
    Start
      - Welcome
      - Textboxes (A)
      - Installation Folder
      - Confirm Installation

    In the Textboxes (A) dialog I have one edit field that I want to make mandatory.

    How can I do that?  I've downloaded the Orca editor.  Is there a simple way to use that to do that?

    These are the two goals I hope to achieve (goal 1 at least)...
    1:
      To enable/disable the next button based on edit label being non-empty
    2:
      Is it possible to validate the contents after hitting the next button?

    Any help is appreciated.

    Thanks!
    Thursday, March 13, 2008 8:56 PM

Answers

  •  

    Hi coder_number_9292,

    If you want to use a custom validating logic, you need to use an unmanaged custom action DLL to do the validating.  You can use the orca tool to edit the ControlEvent table to force the NextButton in the CustomTextA dialog (user interface) to run the custom action. And here are the detailed steps for your reference.

    If you want to show an error dialog when the user didn’t type anything in the textbox, you can use orca tool to replace the following row in ControlEvent table

          CustomTextA | NextButton | NewDialog | [CustomTextA_NextArgs] | CustomTextA_NextArgs<>"" | 1

    With the following row.

          CustomTextA | NextButton | NewDialog | ErrorDialog | EDITA1="" | 1

    Hope this helps.
    Best regards.
    Rong-Chun Zhang

    Wednesday, March 19, 2008 11:38 AM

All replies

  •  

    Hi coder_number_9292,

    If you want to use a custom validating logic, you need to use an unmanaged custom action DLL to do the validating.  You can use the orca tool to edit the ControlEvent table to force the NextButton in the CustomTextA dialog (user interface) to run the custom action. And here are the detailed steps for your reference.

    If you want to show an error dialog when the user didn’t type anything in the textbox, you can use orca tool to replace the following row in ControlEvent table

          CustomTextA | NextButton | NewDialog | [CustomTextA_NextArgs] | CustomTextA_NextArgs<>"" | 1

    With the following row.

          CustomTextA | NextButton | NewDialog | ErrorDialog | EDITA1="" | 1

    Hope this helps.
    Best regards.
    Rong-Chun Zhang

    Wednesday, March 19, 2008 11:38 AM
  • Hi Rong-Chun,

     

    I have similar question as code_number_9292 and I found your answer here. I want just to show the error dialog, therefore I edit the msi file. In my msi it doesn't have the row CustomeTextA at all, so I tried to add it in with the change you suggested, but when I ran the msi it didn't show any error dialog. Do I have to do anything else other than adding the entry in this table?

     

    Is there a way to just disable the Next button and only enable when user enters something in the textbox?

     

    Thanks.

    Monday, March 31, 2008 4:51 AM
  • Hi Rong-Chung Zhang,

    Me also tried  what you said in this post but its not working. My installer raising an error 24778

    can you suggest   the steps to follow to make the Edit Field in the custom action UI Form required and disable the Next button if the user doesn't provide the details.

    Saturday, July 21, 2012 12:49 PM