Solved what I need is if the password found save it

September 6, 2011 at 19:47:02
Specs: Windows 7
(Note: read the simple version of my question after the #### marks at the end)

I have this code (CMD bat file)


@echo
text -u text -w numeric1.txt

this code is for testing passwords

usually if it is find the password I get this 2 lines (I type it exactly)
[+] Password : [X]
[+] Status : Rasta!

X is the password that it is found

what I need is if the password found save it to text file ; and if the password not found then just close the bat file (the default thing happen is close when end if it find the password or not so I need code to change the default )

Can you please help me with that ?


###################

simple version of my question

I need code if the result of my bat file is "[+] Status : Rasta!" then it will save the line above it "[+] Password : [X]"
X is the password

Can you help me with that ?

Regards


See More: what I need is if the password found save it

Report •

#1
September 6, 2011 at 23:41:01
✔ Best Answer
if %status%==Rasta! @echo %password% >> password.txt

Happy is ONE who says I am an OttoMAN.


Report •
Related Solutions


Ask Question