Hi all,
this is regarding timers in palm (I've been thro the archives)
when I parse and render a WAP card I come accross the ontimer tag..which calls
my createTimer function:-
BOOL BrowserTimerExists ;
UInt16 BrowserTimeoutValue;
createTimer(void *usrAgent, uint16 period)
{
BrowserTimerExists = TRUE;
BrowserTimeoutValue = GetTimeMSec() + period*100;
return SUCCESS;
}
where GetTimeMSec() returns the time in milliseconds (this function works)
and then I perform this check in the eventLoop...
do {
status = CheckTimer();
EvtGetEvent(&event, 1);
if (! SysHandleEvent(&event))
if (! MenuHandleEvent(0, &event, &error))
if (! AppHandleEvent(&event))
FrmDispatchEvent(&event);
} while (event.eType != appStopEvent);
Now the above code seems to perform alright and I get the cards rendered on
the screen but at the end when the EvtGetEvent is called after the check timer
it throws up an error : read from Low memory,
Is there something wrong with my timer functions? is there a better way to
implement them?..
my CheckTimer function is given by
CheckTimer()
{
if(BrowserTimerExists)
{
if( NW_Time_GetTimeMSec() >= BrowserTimeoutValue){
return NW_Wml_Timeout(wmlIntepreter);
}
}
}
thanx in advance
vishy
____________________________________________________________________
Get free email and a permanent address at http://www.netaddress.com/?N=1
--
For information on using the ACCESS Developer Forums, or to unsubscribe, please
see http://www.access-company.com/developers/forums/