Sign in to follow this  
Followers 0
seiryklav

Password ---

8 posts in this topic

;Guicreated
    $child = GUICreate("logon", 200, 100,)
    GUISetState(@SW_SHOW, $child)
    GUISetOnEvent($GUI_EVENT_CLOSE, "childclose")

    ;Buttons
    $ok1 = GUICtrlCreateButton("OK", 140, 25, 50, 30)
    GUICtrlSetOnEvent(-1, "writeini")

    ;Inputs
    GUICtrlCreateInput("", 10, 20, 75, 20)
    GUICtrlCreateInput("", 10, 65, 75, 20)

    ;Labels
    $user = GUICtrlCreateLabel("Username", 10, 5, 75, 12)
    $pass = GUICtrlCreateLabel("Password", 10, 50, 75, 12,"" ,$ES_PASSWORD)
    ;GUICtrlSetState(-1, $ES_PASSWORD)

I want the password to be asteriks when it is typed it, and then im going to have another window popup confirming the password... This code isnt making the password asteriks..

help please???


ContactAim- bluehydrolic

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

i just tried

$pass = GUICtrlCreateLabel("Password", 10, 50, 75, 12)
    GUICtrlSetStyle($pass, $ES_PASSWORD)

and it doesn't work

EDIT: *slaps self in head* IM SUCH A NOOB!!! lol.. now it works, when applied to an actual input...

Edited by seiryklav

ContactAim- bluehydrolic

Share this post


Link to post
Share on other sites

now that i got that working...

For some reason when i open a new gui from a previous gui, and i "X" the window, the parent window of the one recently "Xed" doesn't want to "X" out....

i'm going to post the code for this whole shabang... its a guiscript to automatically sign me into myspace... i know it can be done simpler (cause i have one that works), but i want to make it complicated, to learn more about Autoit..

here goes

#include <GUIConstants.au3>

Opt("GUIOnEventMode", 1)

Global $regis = 1, $child = 1, $confirm = 1
#Region ### START Koda GUI section ### Form=
$parent1 = GUICreate("Myspace", 197, 205, 193, 115)
GUISetBkColor(0xFF0000)
GUISetOnEvent($GUI_EVENT_CLOSE, "MyspaceClose")
$Myspace = GUICtrlCreateButton("Myspace", 112, 152, 75, 25, $BS_DEFPUSHBUTTON)
GUICtrlSetOnEvent(-1, "MyspaceClick")
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

Func myspaceclick()
    If FileExists("/Temp/myspace.ini") Then
        $Myspace = 1
    EndIf

    If Not FileExists("/Temp/myspace.ini") Then
        $Myspace = 0
    EndIf
    
    If $Myspace = 0 Then
        $regis = GUICreate("Register", 200, 100)
        GUISetState(@SW_SHOW, $regis)
        GUISetOnEvent($GUI_EVENT_CLOSE, "childclose2")
        GUICtrlCreateLabel("Register for Myspace Auto Logon?", 5, 20, 200, 20)
        GUICtrlCreateButton("OK", 55, 60, 50, 30)
        GUICtrlSetOnEvent(-1, "myspacelogin")

        GUICtrlCreateButton("Cancel", 115, 60, 50, 30)
        GUICtrlSetOnEvent(-1, "childclose2")
    EndIf

    If $Myspace = 1 Then
        Run("C:\Program Files\Mozilla Firefox\firefox.exe")
    EndIf
EndFunc   ;==>myspaceclick

While 1
    Sleep(100)
WEnd


Func myspacelogin()
    Local $regis = 0

    If $regis = 0 Then
        GUIDelete($regis)
    EndIf
    
    
    ;Guicreated
    $child = GUICreate("logon", 200, 100,)
    GUISetOnEvent($GUI_EVENT_CLOSE, "childclose")
    GUISetState(@SW_SHOW, $child)
    

    ;Buttons
    $ok1 = GUICtrlCreateButton("OK", 140, 25, 50, 30)
    GUICtrlSetOnEvent(-1, "confirmpass")

    ;Inputs
    GUICtrlCreateInput("", 10, 20, 75, 20)
    $pass = GUICtrlCreateInput("", 10, 65, 75, 20, $ES_PASSWORD)
    ;Labels
    GUICtrlCreateLabel("Username", 10, 5, 75, 12)
    GUICtrlCreateLabel("Password", 10, 50, 75, 12)
    


EndFunc   ;==>myspacelogin

Func confirmpass()
    $confirm = GUICreate("Confirm", 200, 100)
    GUISetOnEvent($GUI_EVENT_CLOSE, "confirmclose")
    GUISetState(@SW_SHOW, $confirm)
    
    GUICtrlCreateLabel("Please confirm your password.", 10, 5, 75, 12)
    GUICtrlCreateInput("", 10, 65, 75, 20)
    GUICtrlCreateInput("", 10, 65, 75, 20)
    GUICtrlCreateButton("OK", 140, 25, 50, 30)
    
EndFunc   ;==>confirmpass

Func MyspaceClose()
    Exit

EndFunc   ;==>MyspaceClose

Func childclose()
    GUIDelete()
EndFunc   ;==>childclose

Func childclose2()
    GUIDelete()
EndFunc   ;==>childclose2

Func confirmclose()
    GUIDelete()
EndFunc   ;==>confirmclose

ContactAim- bluehydrolic

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

Multipule GUIs, dude.

Save the window ids of the seperate GUIs and use those for the GUIDelete() and what not.

#)

edit: You'd wanna save those in global variables.

Edited by nfwu

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

so it would look something like this

Global $parent, $child, $child2

do i have that right???

EDIT: guess i do.. it works now.. sweet

Edited by seiryklav

ContactAim- bluehydrolic

Share this post


Link to post
Share on other sites

im scouring the help file, but cant find what im looking for now

how can i make a child GUI be created, NOT on top of the parent???


ContactAim- bluehydrolic

Share this post


Link to post
Share on other sites

Share this post


Link to post
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
Sign in to follow this  
Followers 0