My suggestion is to maintain a normal PalmOS event flow, just like the app
had before you added automatic timed screen advancing. That is, each form
should have an event handler that knows how to handle button presses and
such, and the main event loop should look like the starter app's. Then, when
each form is loaded, set a global variable with the current time plus
whatever delay you think is appropriate. This represents the time to switch
to the next form. Now, change your main event loop slightly so that it
computes a suitable delay rather than using evtWaitForever. This delay
should be such that the time after the delay ends up being the time to
switch to the next form, as you stored in a global earlier. Finally, add a
nilEvent case in each form's event handler to check whether it's time to
switch to the next form, and if so, to do the same thing as pressing the OK
button would have (or just post a suitable ctlSelectEvent). You might also
want to allow the user to press the up or down hard scroll buttons to jump
to the previous or next screen.
-- 
Peter Epstein

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/tech/support/forums/

Reply via email to