Question says it all really, but I don't mind if any answers are AS2 or AS3 solutions, just curious really - seems weird that I couldn't 开发者_JS百科find out how to do this really quickly.
Can't you add an event listener to it? Or perhaps set the htmlText's event and handle the event as it arises. Some information can be found here and also here.
AS2
If your using a dynamic text field I assume your filling it with html content. Since this is pure html inside the field it doesn't have a relation between the event model and the html. You need to have an object to access the event model in AS2.
AS3
But in AS3 you can use the event keyword in the href.
http://livedocs.adobe.com/flash/9.0/ActionScriptLangRefV3/flash/text/TextField.html#event:link
http://troyworks.com/blog/2008/03/14/flash-textfield-actionscript-hyperlink-in-as30/
精彩评论