Jump to content

who helped me create gui login ?


xTNL
 Share

Recommended Posts

#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#include <Inet.au3>
#include <GuiComboBox.au3>
#include <GUIConstants.au3>

#Region ### START Koda GUI section ### Form=
$GUI1 = GUICreate("tet", 226, 230,-1,-1,-1,BitOR($WS_EX_ACCEPTFILES, $WS_EX_APPWINDOW, $WS_EX_TOOLWINDOW, $WS_EX_WINDOWEDGE))
GUISetFont(9, 400, 0, "Tahoma")
GUISetBkColor(0x000000)

$Label2 = GUICtrlCreateLabel("ID :", 16, 64, 27, 20)
GUICtrlSetFont(-1, 10, 800, 0, "Tahoma")
GUICtrlSetColor(-1, 0xFFFFFF)
$ID = GUICtrlCreateInput("", 56, 64, 161, 22)
GUICtrlSetFont(-1, 9, 800, 0, "Tahoma")
$Label3 = GUICtrlCreateLabel("Pass :", 8, 104, 43, 20)
GUICtrlSetFont(-1, 10, 800, 0, "Tahoma")
GUICtrlSetColor(-1, 0xFFFFFF)
$PA = GUICtrlCreateInput("", 56, 104, 161, 22, BitOR($ES_PASSWORD,$ES_AUTOHSCROLL))
GUICtrlSetFont(-1, 9, 800, 0, "Tahoma")
$dn = GUICtrlCreateButton("Login", 8, 136, 59, 25, $WS_GROUP)
GUICtrlSetFont(-1, 9, 800, 0, "Tahoma")
GUICtrlSetColor(-1, 0x000000)
$x = GUICtrlCreateButton("Delete", 72, 136, 67, 25, $WS_GROUP)
GUICtrlSetFont(-1, 9, 800, 0, "Tahoma")
GUICtrlSetColor(-1, 0x000000)
$THT = GUICtrlCreateButton("EXIT", 144, 136, 75, 25, $WS_GROUP)
GUICtrlSetFont(-1, 9, 800, 0, "Tahoma")
GUICtrlSetColor(-1, 0x000000)

GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###


GUISetState()

While 1
   $msg = GUIGetMsg()
   if $msg = $gui_event_close then Exit
   if $msg = $THT then Exit
   if $msg = $x then
      GUICtrlSetData($id,"")
      GUICtrlSetData($pa,"")
   EndIf
WEnd
#endregion

Language English : ( I'm from in VietNam . Sorry my English is very bad ) 

When I click on the login, user.php program will check on host .

- If ID and PASS true will check whether any accounts that are not used ,If the account is logged in, notice accounts are logged ,If the account is not logged in, login notifications success

- If ID and Pass false, program will report the wrong ID or PASS

Can I help me ? I would like to thank.

Language VietNam :

Các bạn có thể giúp mình tạo gui login được không ? Khi mình click vào "login", chương trình sẽ kiểm tra tài khoản và pass có đúng với file user.php trên host không ?

- Nếu ID và Pass đúng thì chương trình sẽ kiểm tra xem có ai đang đăng nhập hay không . Nếu đang có người đăng nhập thì chương trình sẽ báo đang có người sử dụng, nếu chưa có ai đăng nhập tài khoản đó thì thông báo đăng nhập thành công.

- Nếu ID và Pass sai thì chương trình sẽ thông báo ID sai hoặc Pass sai .

Mong được mọi người giúp đỡ   :thumbsup:

Link to comment
Share on other sites

  • 2 weeks later...

#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <GUIConstants.au3>

$GUI1 = GUICreate("tet", 226, 230,-1,-1,-1,BitOR($WS_EX_ACCEPTFILES, $WS_EX_APPWINDOW, $WS_EX_TOOLWINDOW, $WS_EX_WINDOWEDGE))
GUISetFont(9, 400, 0, "Tahoma")
GUISetBkColor(0x000000)

$Label2 = GUICtrlCreateLabel("ID :", 16, 64, 27, 20)
GUICtrlSetFont(-1, 10, 800, 0, "Tahoma")
GUICtrlSetColor(-1, 0xFFFFFF)
$ID = GUICtrlCreateInput("", 56, 64, 161, 22)
GUICtrlSetFont(-1, 9, 800, 0, "Tahoma")
$Label3 = GUICtrlCreateLabel("Pass :", 8, 104, 43, 20)
GUICtrlSetFont(-1, 10, 800, 0, "Tahoma")
GUICtrlSetColor(-1, 0xFFFFFF)
$PA = GUICtrlCreateInput("", 56, 104, 161, 22, BitOR($ES_PASSWORD,$ES_AUTOHSCROLL))
GUICtrlSetFont(-1, 9, 800, 0, "Tahoma")
$dn = GUICtrlCreateButton("Login", 8, 136, 59, 25, $WS_GROUP)
GUICtrlSetFont(-1, 9, 800, 0, "Tahoma")
GUICtrlSetColor(-1, 0x000000)
$x = GUICtrlCreateButton("Delete", 72, 136, 67, 25, $WS_GROUP)
GUICtrlSetFont(-1, 9, 800, 0, "Tahoma")
GUICtrlSetColor(-1, 0x000000)
$THT = GUICtrlCreateButton("EXIT", 144, 136, 75, 25, $WS_GROUP)
GUICtrlSetFont(-1, 9, 800, 0, "Tahoma")
GUICtrlSetColor(-1, 0x000000)

GUISetState(@SW_SHOW)

While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit
        Case $THT
            Exit
        Case $x
            GUICtrlSetData($id,"")
            GUICtrlSetData($pa,"")
        Case $dn
            $username = GUICtrlRead($ID)
            $password = GUICtrlRead($PA)

            If $username = "xTNL" Then
            If $password = "communism" Then
            MsgBox(0,"Login","Successful login")
;~          PHP
        Else
            MsgBox(16,"Login","Wrong Password")
            EndIf
        Else
            MsgBox(16,"Login","Wrong Username or Password")
            EndIf

    EndSwitch
WEnd

Edited by Jos
removed the sillyness
Link to comment
Share on other sites

  • Developers

:think: mmm. first post and making a political statement in a piece of provided code.

Any reason you felt this was needed?

Jos

Edited by Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

:think: mmm. first post and making a political statement in a piece of provided code.

Any reason you felt this was needed?

Jos

 

rather why it was necessary to write topic in Vietnamese language ?

Link to comment
Share on other sites

  • Developers

rather why it was necessary to write topic in Vietnamese language ?

That is really none of your business and for us to moderate in case we feel it is needed.

Guess I had hope for a different answer than you trying to defend something silly.

Jos

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

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...