Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #comments-start
- Autor: Ex112
- Acesse: Expertz Cheats.com.br
- #comments-end
- #include <ButtonConstants.au3>
- #include <EditConstants.au3>
- #include <GUIConstantsEx.au3>
- #include <StaticConstants.au3>
- #include <WindowsConstants.au3>
- $Form1 = GUICreate("Sistema de Login - Expertz Cheats", 285, 116, 380, 340)
- GUISetBkColor(0x648BCB)
- $Label1 = GUICtrlCreateLabel("Username:", 16, 16, 91, 24)
- GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif")
- GUICtrlSetCursor (-1, 3)
- $Label2 = GUICtrlCreateLabel("Password:", 16, 48, 86, 24)
- GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif")
- GUICtrlSetCursor (-1, 3)
- $Label3 = GUICtrlCreateLabel("", 104, 192, 4, 4)
- GUICtrlSetFont(-1, 12, 800, 0, "MS Sans Serif")
- $Input1 = GUICtrlCreateInput("", 112, 16, 97, 21)
- $Input2 = GUICtrlCreateInput("", 112, 48, 97, 21)
- $Button1 = GUICtrlCreateButton("Login", 216, 16, 59, 21)
- $Button2 = GUICtrlCreateButton("Exit", 216, 48, 59, 21)
- $Label4 = GUICtrlCreateLabel("Expertz Cheats.com.br", 32, 80, 216, 28)
- GUICtrlSetFont(-1, 14, 800, 0, "MS Sans Serif")
- GUICtrlSetCursor (-1, 3)
- GUISetState(@SW_SHOW)
- While 1
- $nMsg = GUIGetMsg()
- $vUsername = GuiCtrlRead ($Input1); Lê o que está escrito no Input1 (campo username)
- $vPassword = GuiCtrlRead ($Input2); Lê o que está escrito no Input2 (campo password)
- Switch $nMsg
- Case $GUI_EVENT_CLOSE
- Exit
- Case $Button2; dá função ao Button2 (botão Exit)
- Exit; finaliza o programa
- Case $Button1; dá função ao Button1 (botão Login)
- If Login($vUsername, $vPassword) = "Login" Then; verifica se username e passwords estão de acordo com gravado no programa
- MsgBox (64, 'Expertz Cheats', 'Logado com Sucesso'); se username e password estiverem corretos exibe msg de login
- _Principal();chama a form principal ou algum programa externo ou outra coisa, aee vai do qee vc quer
- Else; caso username e password estejam incorretos,
- MsgBox (16, 'Expertz Cheats', 'Username ou Passwords Incorretos'); exibe a msg de erro
- EndIf
- EndSwitch
- WEnd
- Func Login ($Username, $Password)
- If $Username = 'Ex112' And $Password = 'Expertz Cheats' Then; faz a verificação doq foi digitado no input e oqee está gravado
- Return ('Login'); se for igual retorna "Login"
- Else; se ñ for
- Return ('Error'); retorna Error
- EndIf
- EndFunc
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement