Posted 02 November 2013 - 12:23 PM
Hello, I'm back again… :P/>
I have on my OS, a desktop, and on this desktop a menu bar, on this menu bar I want the time to update, I've gotten it to show
the time, and it updates whenever I click a button, but how can I get it to read for a button click and update the time at the same time?
Code (Extracted from desktop program):
Thanks in advance, most helpful reply/replies will get credit.
I have on my OS, a desktop, and on this desktop a menu bar, on this menu bar I want the time to update, I've gotten it to show
the time, and it updates whenever I click a button, but how can I get it to read for a button click and update the time at the same time?
Code (Extracted from desktop program):
local function bar()
term.setBackgroundColor(2)
term.setTextColor(1)
term.setCursorPos(1,1)
term.clearLine()
term.setCursorPos(1,1)
local time = os.time()
time = textutils.formatTime(time, false)
print("[Menu] | "..user.getCurrent().." | "..time)
term.setCursorPos(47,1)
print(ver)
term.setCursorPos(50,18)
print("[<")
end
Thanks in advance, most helpful reply/replies will get credit.