Jump to content

need some help with my script code


 Share

Recommended Posts

:whistle: heres my code

#include <GUIConstants.au3>

GUICreate(" My GUI input acceptfile", 320,120)

GUICtrlCreateLabel('Enter your MTGO username',10,12)

$input1 = GUICtrlCreateInput ( "", 10, 30, 300, 20)

GUICtrlCreateLabel('Enter your MTGO password',10,54)

$input2 = GUICtrlCreateInput ("", 10, 70, 300, 20)

$okbtn = GUICtrlCreateButton ("Ok", 40, 95, 60, 20)

$exitbtn = GUICtrlCreateButton ("Exit", 120, 95, 60, 20)

GUISetState ()

$msg = 0

While $msg <> $GUI_EVENT_CLOSE

$msg = GUIGetMsg()

Select

Case $msg = $exitbtn

exitloop

Case $msg = $okbtn

$x = GUICtrlRead($input1)

$y = GUICtrlRead($input2)

MouseClick("left", 424, 356)

Send($x)

MouseClick("left", 434, 413)

Send($y)

MouseClick("left", 491, 444)

EndSelect

Wend

what i need to do is when the Ok button gets pressed is that the form will close but will still type the text that has been enterd in the boxs and i need the 2ed textboxs text to look like **** when someone enters text in it plz help me

Link to comment
Share on other sites

maybe...

#include <GUIConstants.au3>
$myGUI = GUICreate(" My GUI input acceptfile", 320, 120)
GUICtrlCreateLabel('Enter your MTGO username', 10, 12)
$input1 = GUICtrlCreateInput("", 10, 30, 300, 20, $ES_PASSWORD)
GUICtrlCreateLabel('Enter your MTGO password', 10, 54)
$input2 = GUICtrlCreateInput("", 10, 70, 300, 20)
$okbtn = GUICtrlCreateButton("Ok", 40, 95, 60, 20)
$exitbtn = GUICtrlCreateButton("Exit", 120, 95, 60, 20)
GUISetState()
$msg = 0
While $msg <> $GUI_EVENT_CLOSE
    $msg = GUIGetMsg()
    Select
        Case $msg = $exitbtn
            ExitLoop
        Case $msg = $okbtn
            $x = GUICtrlRead($input1)
            $y = GUICtrlRead($input2)
            GUISetState( @SW_HIDE, $myGUI)
            MouseClick("left", 424, 356)
            Send($x)
            MouseClick("left", 434, 413)
            Send($y)
            MouseClick("left", 491, 444)
    EndSelect
WEnd

8)

NEWHeader1.png

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