Help, again;
My program has a nice Splash screen that cancles well
by clicking or hitting, Return or Cancel.
Decided to add a Timed out feature using ENTERPROC code
from article by Robert Schenk in Inside Basic, Vol 5, No 1
January 1995.
Times out, then re-appears, times out, re-appears etc.
in infinite cycle until clicked on. WON'T respond to
Return or Cancel.
Uses following code. ENTERPROC is in first segment (there
are other ENTERPROCS in this program.
Can call AboutMAF splash screen from Apple Menu
with with a%=FN ALERT(_AboutMAF,0) BUT this doesn't time out.
Replacing 0 with myFilterAddr& causes alert to flash
on and cancel once. What kind of error am I looking for.
Has anyone know what's happening or why?
OK Button = item 1, cancel Btn = item 2, Spash screen
graphic = item 3
boolean, Key, Hitee&, dialogPtr&, EvtPtr&, myFilterAddr&
timeOut& and tocks& all DIM'd in GLOBALS
GOTO "endSkip"
"myFilter"
ENTERPROC(dialogPtr&, EvtPtr&, Hitee&)
boolean = 0
LONG IF {EvtPtr}=_KeyDwnEvt
Key = PEEK(EvtPtr& + _evtMessage + 3)
SELECT CASE Key
CASE 27 'Escape=27
boolean = -1 'cancel Btn
%Hitee&, 2
CASE 13, 3 'Return or Enter
boolean = -1
%Hitee&, 1
CASE ELSE
END SELECT
XELSE
tocks&=FN TICKCOUNT
LONG IF tocks&>timeOut&
boolean = -1
%Hitee&, 151
END IF
END IF
EXITPROC = boolean
"endSkip"
LOCAL FN InitAbout
a%=151
WHILE a%=151
timeOut&=FN TICKCOUNT+360 'add 6 seconds
myFilterAddr&=LINE "myFilter"
a%=FN ALERT(_AboutMAF,myFilterAddr&)
DELAY 500
WEND
END FN
'--------Main-------
FN InitAbout
__ ____
Bob Bryce Canadian Bible Society || | ||
Algonquian Translation Project ||Itwewin||
rbryce@... Translation-CAP Department || | ||
(rbryce@...)Phone (306) 384-8225 ||___ ___||