Jump to content

This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.

Conditional PushButton on Dialog

2 replies to this topic


  • Members
  • 35 posts

Posted 06 December 2001 - 11:17

I have a dialog box with a property CODE1 where you need to input a code.

When I click the Next button I want it to go to the next dialog box only if the code is right.

I can get this to work if I put in:
but I want it to also work if it is "PK34H"
I've tried everything I can think of:
CODE1="PK12H" Or CODE1="PK34H" etc but it won't work.

Please help.



  • Members
  • 227 posts

Posted 17 December 2001 - 17:18

Did you try "OR" (all upper case)?

Kurt Schneider

Kurt Schneider
  • Members
  • 98 posts

Posted 20 December 2001 - 21:00


How about enclosing everything in ()

(CODE1="PK12H" Or CODE1="PK34H" )

If that doesn't work you ocould always try a Custom Action using some VBScript  example below:

Make sure that you create a Property in the Property Manager called MOVEALONG.  I would also set its value to No.


Option Explicit


Sub Main()

    Dim sVar

    sVar = Session.Property("CODE1")

    If (sVar = "PK12H" OR sVar = "PK34H") Then
          Session.Property("MOVEALONG") = "Yes"
          Exit Sub
  MsgBox "Wrong Code, try again!"
    End If

End Sub


Now in the Dialog Editor set the behavior on the next Button as follows

Event                   Argument             Condition
DoAction             CA Name             1
New Dialog        NextDialog           MOVEALONG = "Yes"

Good Luck