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...
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.
also see topic flash.ui.keyboard there enter constant has value of 13.
More discussions in Flex (Read Only)
adobe
Comments
Post a Comment