Jump to content

i want to make some complex Script


Recommended Posts

well i want to make a complex script ( complex because i dont know all the commands and how to use them)

well i want to make a script that is asking for a password and if i type the password corect i must go in some program that i can add text or things like those can some one help me with something ??

i make this but it dosent work :-| at the IF-ELSE

well and how do i give a value to the $password2 = ???

so please help me with some idea and source code i really want to make it :shocked:

Thank you very much

$password1 = InputBox("Enter the Password", "Enter the password for your Documents and things - Moisoiu Mircea Mihai.", "", "*")
$password2 = 4
if $password1 = $password2 
MsgBox(0,"Password Corect", "Welcome Moisoiu Mircea Mihai")
then
Link to comment
Share on other sites

if you are wanting to have an entire program run if the password is correct, you may want to make it...

$passinput = InputBox("Enter the Password", "Enter the password for your Documents and things - Moisoiu Mircea Mihai.", "", "*")
$password = 4
If $passinput <> $password then Exit
MsgBox(0,"Password Corect", "Welcome Moisoiu Mircea Mihai")
Edited by daslick
Link to comment
Share on other sites

dang how to you is working ?? how did you figure it out O_O my god :-| Thank you very much

by the way i may need a little more help from you with some answers at this question

1)how is it working with IF and ELSE not only Then

2)and how do i make it if i type a wrong password and not 4 to not ENTER ??? is something like this

$password1 = InputBox("Enter the Password", "Enter the password for your Documents and things - Moisoiu Mircea Mihai.", "", "*")
$password2 = 4
if $password1 = $password2 then
    MsgBox(0,"Password Corect", "Welcome Moisoiu Mircea Mihai")
EndIf
Else
or how ?
Link to comment
Share on other sites

Thank you very very much and now for my last and very important question

how can i make the script if i type some Text for an example the script to dont forget it and save it in the .exe file from were i start the program ???

is there some command or something and can you give me some example to know how to make it on the future ? ( sorry guys i am a begginer and i ma trying to learning from my little mistakes )

Link to comment
Share on other sites

well i want to make a Password Bank script

so what i was saying is => i type a text for example MONEY when i type MONEY i want the Password Bank.exe file to remeber it in the .exe not in a .txt file

so can you help me with this

Link to comment
Share on other sites

  • Developers

well i want to make a Password Bank script

so what i was saying is => i type a text for example MONEY when i type MONEY i want the Password Bank.exe file to remeber it in the .exe not in a .txt file

so can you help me with this

Won't work that way, but what about you start doing some basic reading and looking at the helpfile examples first so you better understand what you need to ask help on.

:shocked:

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

Well i make this is good but my only problem is at =>> do

If $passinput <> $password then msgbox(0,"Wrong Password", "The Password you type is wrong") <<== is continuing repeting it selfs, how do i make it to enter again the password or something like that

And By the way how do i encrypt a .txt file ( i really want to make some Password DB ) :shocked: Begginer but with full ideas :(

#include <File.au3>
#include <GUIConstants.au3>

$passinput = InputBox("Introdu Parola Moisoiu Mircea Mihai", "Introduce-ti parola de acces la baza de date - Moisoiu Mircea Mihai.", "", "*")
$password = FileReadLine("D:\test.txt",1)
do
If $passinput <> $password then msgbox(0,"Wrong Password", "The Password you type is wrong")
        


Until $passinput = $password
MsgBox(0,"Password Corect", "Welcome Moisoiu Mircea Mihai")
Edited by mircea
Link to comment
Share on other sites

Your line that gets the $passinput should be inside the Do loop, just before you check to see if it is correct

Like this:

#include <File.au3>
#include <GUIConstants.au3>

$password = FileReadLine("D:\test.txt",1)
Do
    $passinput = InputBox("Introdu Parola Moisoiu Mircea Mihai", "Introduce-ti parola de acces la baza de date - Moisoiu Mircea Mihai.", "", "*")
    If $passinput <> $password then msgbox(0,"Wrong Password", "The Password you type is wrong")
Until $passinput = $password
MsgBox(0,"Password Corect", "Welcome Moisoiu Mircea Mihai")

As for file encrypting you might want to check out http://www.autoitscript.com/forum/index.ph...&hl=encrypt

One other thing you might want to do is to check to see if File opened properly, and if it didn't then exit the script.

Otherwise just deleting the file will make a password not neccesary.

Link to comment
Share on other sites

thank you right now i was thinking at what you write :shocked:) lol

by the way i check the little things with the Encrypt and i am looking at something that i never see in my life i dont know how to use that ( sorry i am a begginer in programing)

Edited by mircea
Link to comment
Share on other sites

Maybe the _StringEncrypt function would be more what you want.

Try the following, the first code will set your password in the textfile, the second one is your script.

#include <String.au3>
$passwordfile = "D:\test.txt"
$password = InputBox( "Set your password", "Type in the password to set", "","*")
$encrypted_password = _StringEncrypt ( 1, $password, $password )
$FileHandle = FileOpen( $passwordfile, 2 )
FileWrite( $passwordfile, $encrypted_password )
FileClose( $FileHandle )oÝ÷ Ù«­¢+Ø¥¹±Õ±Ðí¥±¹ÔÌÐì(¥¹±Õ±ÐíU%
½¹ÍѹÑ̹ÔÌÐì(¥¹±Õ±ÐíMÑÉ¥¹¹ÔÌÐì((ÀÌØí¹ÉåÁÑ}ÁÍÍݽÉô¥±I1¥¹ ÅÕ½ÐíèÀäÈíÑÍйÑáÐÅÕ½Ðì°Ä¤)¼(ÀÌØíÁÍÍ¥¹ÁÕÐô%¹ÁÕÑ   ½à ÅÕ½Ðí%¹ÑɽÔAɽ±5½¥Í½¥Ô5¥É5¥¡¤ÅÕ½Ðì°ÅÕ½Ðí%¹ÑɽյѤÁɽ±Ì±éÑ´5½¥Í½¥Ô5¥É5¥¡¤¸ÅÕ½Ðì°ÅÕ½ÐìÅÕ½Ðì°ÅÕ½Ðì¨ÅÕ½Ðì¤($ÀÌØí¹ÉåÁÑ}ÁÍÍ¥¹ÁÕÐô}MÑÉ¥¹¹ÉåÁÐ Ä°ÀÌØíÁÍÍ¥¹ÁÕаÀÌØíÁÍÍ¥¹ÁÕФ(%ÀÌØí¹ÉåÁÑ}ÁÍÍ¥¹ÁÕбÐìÐìÀÌØí¹ÉåÁÑ}ÁÍÍݽÉÑ¡¸µÍ½à À°ÅÕ½Ðí]ɽ¹AÍÍݽÉÅÕ½Ðì°ÅÕ½ÐíQ¡AÍÍݽÉå½ÔÑåÁ¥ÌÝɽ¹ÅÕ½Ðì¤)U¹Ñ¥°ÀÌØí¹ÉåÁÑ}ÁÍÍ¥¹ÁÕÐôÀÌØí¹ÉåÁÑ}ÁÍÍݽÉ)5Í ½à À°ÅÕ½ÐíAÍÍݽÉ
½ÉÐÅÕ½Ðì°ÅÕ½Ðí]±½µ5½¥Í½¥Ô5¥É5¥¡¤ÅÕ½Ðì
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...