[jawsscripts] Re: Help with a script

Hi,

there are several valid ways of approaching this.

Below is my preferred method.
The line:
Delay (3) IF IsKeyWaiting () THEN RETURN ENDIF

smoothes the saying of any information in the double hit situation, & is 
optional


Script TestOnF8 ()

IF IsSameScript () THEN ; double or more hits

SayString ("double") ; for testing only

; do the double hit things

ELSE ;single hit

Delay (3) IF IsKeyWaiting () THEN RETURN ENDIF

SayString ("single") ; for testing only

; do the single hit things

ENDIF

EndScript



----- Original Message ----- 
From: "D!J!X!" <megamansuperior@xxxxxxxxxxx>


Hello list, Here's my scenario.

I created a script, but I want it to perform something different if that
script's key is pressed twice in a row. I'm aware of the IsSameScript
function, however the IsSameScript function performs the original script
ones before doing whatever I call if the IsSameScript function is true.
Basically, I want the script to run something if the key is pressed once,
and something completely different if the key is pressed twice. No matter
what, when I press the key twice, the second set of instructions is
performed, but the first set is also performed. I want a way to stop it from
doing so. I've tried if statements, using values returned from the
IsSameScript function, but no go.  Any ideas???

Thanks, D!J!X!

__________ 
Visit and contribute to The JAWS Script Repository http://jawsscripts.com

View the list's information and change your settings at 
http://www.freelists.org/list/jawsscripts

Other related posts: