anhdh

Untitled

Jun 26th, 2016
93
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
AutoIt 0.96 KB | None | 0 0
  1. #include <ButtonConstants.au3>
  2. #include <EditConstants.au3>
  3. #include <GUIConstantsEx.au3>
  4. #include <StaticConstants.au3>
  5. #include <WindowsConstants.au3>
  6. #Region ### START Koda GUI section ### Form=
  7. $Form1 = GUICreate("Tinh Toan", 615, 438, 192, 124)
  8. $Label1 = GUICtrlCreateLabel("7 x 1 = ", 16, 24, 39, 17)
  9. $Label2 = GUICtrlCreateLabel("7 x 2 = ", 16, 64, 39, 17)
  10. $kq1 = GUICtrlCreateInput("", 64, 24, 121, 21)
  11. $kq2 = GUICtrlCreateInput("", 64, 64, 121, 21)
  12. $kiemtra1 = GUICtrlCreateButton("Kiem Tra", 216, 24, 75, 25)
  13. $kiemtra2 = GUICtrlCreateButton("Kiem Tra", 216, 64, 75, 25)
  14. GUISetState(@SW_SHOW)
  15. #EndRegion ### END Koda GUI section ###
  16.  
  17. While 1
  18.     $nMsg = GUIGetMsg()
  19.     Switch $nMsg
  20.         Case $GUI_EVENT_CLOSE
  21.             Exit
  22.         Case $kiemtra1
  23.             If GUICtrlRead($kq1) = 7 Then
  24.                 MsgBox(0 , "Thông Báo" , "Chuẩn cmnr" , 2)
  25.             EndIf
  26.         Case $kiemtra2
  27.             If GUICtrlRead($kq2) = 14 Then
  28.                 MsgBox(0 , "Thông Báo" , "Chuẩn cmnr" , 2)
  29.             EndIf
  30.  
  31.     EndSwitch
  32. WEnd
Advertisement
Add Comment
Please, Sign In to add comment