Jump to content

I can't find a solution...


Rawox
 Share

Recommended Posts

#include <GUIConstantsEx.au3>
#include <SliderConstants.au3>


$Window = GUICreate ( "The Love Tester", 325, 140 )
    GUICtrlCreateLabel ( "Name 1:", 10, 7 )
    GUICtrlCreateLabel ( "Name 2:", 165, 7 )
    $Name1 = GUICtrlCreateInput ( "", 10, 24, 150, 20  )
    $Name2 = GUICtrlCreateInput ( "", 165, 24, 150, 20 )
    $Calculate = GUICtrlCreateButton ( "Calculate the love!", 10, 50, 305, 25 )
    $Slider1 = GUICtrlCreateSlider ( 10, 80, 305, 30, BitOr ( $TBS_NOTICKS, $GUI_DISABLE ) )
    GUICtrlCreateLabel ( "The result:", 18, 115 )
    
    $ResultLabel = GUICtrlCreateLabel ( "", 100, 115, 2000, 2000 )
    GUICtrlSetFont ( $ResultLabel, 8.5, 600 )
    GUICtrlSetLimit ( -1, 200, 0 )
GUISetState ( @SW_SHOW, $Window )
                
While 1
    $nMsg = GUIGetMsg()
        Select
        Case $nMsg = $GUI_EVENT_CLOSE
            Exit
        Case $nMsg = $Calculate
            If $Name1 = "Henk" Then
                MsgBox(4096,"", "Henk")
            ElseIf $Name1 = "Cas" Then
                MsgBox(4096,"", "Cas.")
            Else
                If $Name1 = "" And $Name2 = "" Then
                    MsgBox(4096,"", "Empty!")
                Else
                    MsgBox(4096,"", "Unknown")
                EndIf
            EndIf
    EndSelect
WEnd

Does anyone know why this isn't working? I just can't figure it out...

Link to comment
Share on other sites

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...