ENTER Key


is correct way check enter key ?

public function initapp():void
{
stage.addeventlistener(keyboardevent.key_down,testcheck)
}


public function testcheck(button1:keyboardevent):void
{
if(button1.keycode==13)
{
alert.show('this works');
}
}


the id button on stage button1. tried using code button1.addeventlistener, code failed there, added stage.addeventlistener(what using now), fails....so presume something's not right here...

the not clear...

check out topic: defining default button
also see topic flash.ui.keyboard there enter constant has value of 13.


More discussions in Flex (Read Only)


adobe

Comments

Popular posts from this blog

VIDIOC_S_FMT error 16, Device or resource busy - Raspberry Pi Forums

using a laptop skeleton to build a pi laptop - Raspberry Pi Forums

Forum for Joomla? - Joomla! Forum - community, help and support