- Sky
- Blueberry
- Slate
- Blackcurrant
- Watermelon
- Strawberry
- Orange
- Banana
- Apple
- Emerald
- Chocolate
- Charcoal
roadrunner116
-
Content Count
4 -
Joined
-
Last visited
Posts posted by roadrunner116
-
-
Sorry, I was away for a week.
Thanks for your replys, now it works.
Try cd / instead so if it is in root it will stay there, if it isn't it will go straight to root.
Also avoid shell.run("rm ") because there is an API method to do it and, while yes it is miniscule, it improves performance of the script and is just good practice.
Which method are you referring to?
-
Hi,
how do I terminate my program, so the user is able to get back to openOS?
Thanks!
-
Hi,
I'm trying to remove a folder and a file from my Update Script before downloading the new stuff. Somehow the way I'm trying I don't have the right permissions. What am I doing wrong.
-- remove old local ok, err = pcall(shell.execute,"cd..") if not ok then print("Problem: ",ok,err,computer.freeMemory()) end local ok, err = pcall(shell.execute,"rm sg") if not ok then print("Problem: ",ok,err,computer.freeMemory()) end local ok, err = pcall(shell.execute,"rm autorun.lua") if not ok then print("Problem: ",ok,err,computer.freeMemory()) end
Thanks!
Terminate my Program
in Programming
Posted
Sorry. Like i wrote in my other post, I was away for a week.
Those three way are the ways I know. I would like to Terminate the script from inside my code, but os.sleep() just does nothing.
This is the way I tried to close the Application.
The button flashes and if I put in a print() it also prints my text. So the touch-event handling seems to work