|
Post by benny303 on Feb 27, 2013 20:19:46 GMT -5
so this program i am writing has this problem with this error code 'end' expected (to close 'if' at line14) Attachments:
|
|
|
Post by carsonh4te on May 16, 2014 16:05:19 GMT -5
--I think I fixed it... try and if not just tell me-- --Code is Below--
term.clear() term.setCursorPos(1,1)
username = "Your Username" password = "Your Password"
write("Welcome please enter your username and password") term.setCursorPos(12,5) -- put screen cords here print("Username: ") term.setCursorPos(12,6) -- and here print("Password: ") term.setCursorPos(23,5) -- same as first ones but over right input = read() if input == username term.setCursorPos(23,6) -- and here else term.setCursorPos(23,6) input = read if input == password then term.clear() term.setCursorPos(1,1) write("Username Or Password Incorrrect Try Again") sleep(2) os.reboot() end input = read() if input == password term.clear() term.setCursorPos(1,1) print("Access Granted!") sleep(2) term.clear() term.setCursorPos(1,1)
end
else term.clear() term.setCursorPos(1,1) print("Access Denied, System Shutting Down!!!") sleep(2) os.reboot()
end
|
|