Page 1 of 1
acceleratorKey for spacebar
Posted: Sat Apr 18, 2015 12:09 pm
by Ultravibe
Hello!
I need to use Spacebar key for some operations (like start & stop).
in card's script i have construction like this:
Code: Select all
set acceleratorKey of btn "TimerButton" to ...
which spelling i should use to set Spacebar as accelerator Key?
Re: acceleratorKey for spacebar
Posted: Sat Apr 18, 2015 1:06 pm
by Klaus
Hi Ultravibe,
I would try SPACE, but remember that you also need to set -> the acceleratorModifiers
to make the acceleratorkey work.
Best
Klaus
Re: acceleratorKey for spacebar
Posted: Sat Apr 18, 2015 5:39 pm
by Ultravibe
I've tried SPACE but it doesn't work... what am i gonna do?
Re: acceleratorKey for spacebar
Posted: Sat Apr 18, 2015 6:18 pm
by Klaus
Hi Ultravibe,
I never messed around with this "accelerator" stuff, too Windows like for me old time Mac-user
Try something like this in the card script, this is what I do usually:
Code: Select all
on keydown tKey
if tKey = SPACE then
send "mouseup" to btn "you know which one..."
## or do whatever you need to do here...
else
pass keydown
end if
end keydown
You get the picture...
Best
Klaus
Re: acceleratorKey for spacebar
Posted: Sat Apr 18, 2015 9:41 pm
by Ultravibe
Thank you, Klaus!
it works!!!!!!