beg.webmaster
06-14-2008, 03:31 PM
I'm trying to make a very simple username & password system with VBScript. They get 2 tries and if they get them both wrong a Message loops and won't let them do anything else. But I have var1=MsgBox("Prompt",0+48+0+4096,"???"), and it's still is letting me click somewhere other then the Message:confused:. I'll post my code, please check to make sure everything is ok...
Username=InputBox("Username:","Enter your Username")
if Username="username" then
Password=InputBox("Password:","Enter your Password")
else
msg1=MsgBox("Username incorrect.",0,"Error")
End if
if Password="password" then
MsgBox("Logged In")
else
msg1=MsgBox("Password incorrect.",0,"Error")
tryAgain=MsgBox("Try Again?",4,"Try Again?")
End if
if tryAgain=6 then
Username=InputBox("Username:","Enter your Username")
if Username="username" then
Password=InputBox("Password:","Enter your Password")
else
msg1=MsgBox("Username incorrect.",0,"Error")
End if
if Password="password" then
login=MsgBox("Logged In")
else
msg1=MsgBox("Password incorrect.",0,"Error")
Do Until You="Leave"
var1=MsgBox("Who Are You",0+48+0+4096,"???")
Loop
End if
End if
Username=InputBox("Username:","Enter your Username")
if Username="username" then
Password=InputBox("Password:","Enter your Password")
else
msg1=MsgBox("Username incorrect.",0,"Error")
End if
if Password="password" then
MsgBox("Logged In")
else
msg1=MsgBox("Password incorrect.",0,"Error")
tryAgain=MsgBox("Try Again?",4,"Try Again?")
End if
if tryAgain=6 then
Username=InputBox("Username:","Enter your Username")
if Username="username" then
Password=InputBox("Password:","Enter your Password")
else
msg1=MsgBox("Username incorrect.",0,"Error")
End if
if Password="password" then
login=MsgBox("Logged In")
else
msg1=MsgBox("Password incorrect.",0,"Error")
Do Until You="Leave"
var1=MsgBox("Who Are You",0+48+0+4096,"???")
Loop
End if
End if