Jump to content

546f6d6173

Members
  • Posts

    2
  • Joined

  • Last visited

546f6d6173's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. Oh my.. I was really used $val1 and $val2 instead of $v1 and $v2. Of course... But the main problem was here: Number(GUICtrlRead($val1)). Now it's working fine! Many thanks for all ! Bye.
  2. Hi all. I heave question. Why do not working this comparison of two values ? It compare correct only first two position of numbers. Try to write for example 100 and 50. Where is the problem?? Sorry for my english. Many thanks. CODE#include <GUIConstants.au3> GuiCreate("Compare two values", 280, 200, 200, 200) $val1 = GUICtrlCreateInput ( "", 20, 110, 50, 20) $name1 = GUICtrlCreateLabel("First value", 75, 115, 60, 20) $val2 = GUICtrlCreateInput ( "", 20, 130, 50, 20 ) $name2 = GUICtrlCreateLabel("second value", 75, 135, 80, 20) $okbt = GUICtrlCreateButton("OK", 170, 130, 60, 20) GUISetState() Do $msg = GUIGetMsg() if $msg = $okbt Then $v1 = GUICtrlRead($val1) $v2 = GUICtrlRead($val2) MsgBox(0,"Info","First value is: " & $v1) MsgBox(0,"Info","Second value is: " & $v2) ;---------------------- if $val1 > $val2 Then MsgBox(0,"Info","First value is GREATER than second") ExitLoop Else MsgBox(0,"info","First value is SMALLER than second") EndIf ;--------------------- ExitLoop EndIf Until $msg = $GUI_EVENT_CLOSE
×
×
  • Create New...