Jump to content

Password


poisonkiller
 Share

Recommended Posts

So... You can protect your computer or user with this. Password = "autoit".You can change it by changing code, but im working with password changer.

#include <GUIConstants.au3>
#Include <Misc.au3>
#NoTrayIcon
GUICreate("Password", 1200, 1200)
HotkeySet("{Esc}", "captureEsc")
HotKeySet("{Enter}", "PressButton")

$pass = GUICtrlCreateInput ("", 470,  560, 300, 20, $ES_PASSWORD)
$button = GUICtrlCreateButton ("OK", 600, 600, 50, 30)
GUISetState ()


While 1
    $msg = GUIGetMsg()

If $msg = $button Then

if GUICtrlRead($pass) = "autoit" Then
MsgBox(0, "Password", "Correct!")
Else 
MsgBox(16, "Error", "Access is denied!Logging out in 3 seconds!", 3)
Shutdown(0)
endif

ExitLoop
EndIf
If _IsPressed("12", "user32.dll") Then
    MsgBox(16, "Error!", "Alt key is not allowed!")
    EndIf
        
        If _IsPressed("2E", "user32.dll") Then
    MsgBox(16, "Error!", "Delete key is not allowed")
    EndIf
        If _IsPressed("73", "user32.dll") Then
    Shutdown(0)
    EndIf
        If $msg = $GUI_EVENT_CLOSE Then ExitLoop
Wend
Func captureEsc()
    MsgBox(16, "Error!", "Escape is not allowed!")
EndFunc

Func PressButton()
    $msg = $button
EndFunc
Link to comment
Share on other sites

Hi!

Looks nice for a first view!

Keep it up, peethebee

p.s. only looked on the code, not tested it yet.

vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvGerman Forums: http://www.autoit.deGerman Help File: http://autoit.de/hilfe vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv

Link to comment
Share on other sites

how do you start your prog? autostart? cause if you start it by autostart it's no use at all cause you can just disable it by pressing SHIFT.

you should call it as an .dll via registry or something like that

maybe it works with exe as well (haven't tried)

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