Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --this program searchs for errors, checks what Program sent the Error, and displays what Actions the User can take to fix the Error, or bypass it
- local w, h = term.getSize()
- function Search()
- local event, id, success, reason = os.pullEvent("task_complete")
- if success == true then
- Search()
- else
- ErrorDetected(id, reason)
- end
- end
- function ErrorDetected(id, reason)
- term.clear()
- print("error has occured in "..id)
- print(id.."-"..reason)
- print("please choose which action to commence")
- print("1 - Shutdown")
- print("2 - return to menu")
- print("3 - start Scan")
- while true do
- local event, key = os.pullEvent("key")
- if key == keys.one then
- shell.switchTab(1,shell.run("ShutdownPrompt"))
- break
- elseif key == keys.two then
- shell.switchTab(1,shell.run("ApertureOS_Base"))
- break
- elseif key == keys.three then
- shell.switchTab(1,shell.run("ShutdownPrompt"))
- break
- end
- end
- end
- Search()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement