03-01-2010 03:52 PM
I am making an Alarm app for the blackberry. Right now I think there will be a background app that is always running and the it implements the RealtimeCLockListener interface so that when the clock reaches the alarm time it will start the alarm. After starting the alarm though I will need to update a screen every second. How can I do something every second or know when every second passes to update the screen?
On another note will the background app keep running even if there is no current alarm and nothing being done at the moment?
Thanks for the help.
03-01-2010 04:08 PM
Your alarm screen will need an "updater" thread that performs this update process.
See Thread class in the javadocs.
Since your "updater" thread will not be the UI thread, interaction with the UI should be done using UiApplication.invokeLater().