You can stop the device going to sleep by playing with the auto off timer. See Evt***AutoOffTimer(). There are several functions that call this internally, but FrmDoDialog should not do this, unless you provide your own event handler and do it yourself. Other than that, I don't know what would cause it.
This doesn't help much, but might give you some clues. Does it occur on a real device or just on the emulator? Matt ----- Original Message ----- From: "Ryan Bruner" <[EMAIL PROTECTED]> To: "Palm Developer Forum" <[EMAIL PROTECTED]> Sent: Friday, June 06, 2003 5:07 AM Subject: Not going to sleep..please help! > > > I've now been struggling with this issue for 2 weeks, with no clue as > to the cause. I posted questions twice, but no one has responded yet, > so I'm trying yet again. > > My application sets an alarm. When the alarm fires, I respond to the > trigger event by sounding the alarm, and then I respond to the alarm > Display event to pop up a window informing the user of the alarm. > Previously I used FrmCustomerAlert, but changed this to a custom > FrmDoDialog recently trying to alleviate my problem. Both have the > same problem, however... > > Recently, when the alarm fires, the PDA won't go back to sleep. While > my dialog is being displayed, the power of the PDA will stay on > forever, causing serious battery drain issues. However, I have no clue > as to how this is possible. Basically, my alarm is "stuck" in the > FrmDoDialog. So, why won't it go to sleep? > > This has been working fine for months. I made several code changes to > some code unrelated to my alarms, and now this is happening. > > So, the basic question is what can cause the PDA to NOT enter sleep > mode? Note that in all other screens on my application, the PDA will > sleep without problems...it is just the alarm that is the issue. > > Thanks! > > Ryan > > > > -- > For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/ > > -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
