开发者

Flex text mouse over functionality

I need to develop some mouse over functionality in text field.

I could get the text on click functionality by having htmlText & TextEvent.

Similarly开发者_StackOverflow, can i get the mouseover functionality in text field ?


why use htmlText and TextEvent for on click functionality? click functionality is present in flex.So is mouse over..

     <?xml version="1.0" encoding="utf-8"?>
 <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
 <mx:Script>
    <![CDATA[
        public function clickHandler(event:MouseEvent):void{
        //handle click here..
        }
        public function mouseOverHandler(event:MouseEvent):void{
               //handle mouse over event here..
        }
    ]]>
</mx:Script>
<mx:Text x="84" y="72" text="Text" width="212" height="43" click="clickHandler(event)"  mouseOver="mouseOverHandler(event)"/>


        private function onMouseOver(event:MouseEvent):void
        {
            Alert.show('Hello Ankur Sharma');
        }
    ]]>
</mx:Script>    

Hey this is done using TextField, if u were talkin abt TextField(i used flex3)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜