Namespace the ho! Think of namespaces like imports. import mx.controls.TextArea;
That allows you to do: var a:TextArea = new TextArea(); So do like: <view:MyClass xmlns:view="your.package.path.*" /> Or, if you are going to use MyClass multiple times, but the xmlns:view stuff in your root tag so you only have to write it once. ----- Original Message ----- From: "jpc14_99" <[EMAIL PROTECTED]> To: <[email protected]> Sent: Tuesday, July 25, 2006 5:47 PM Subject: [flexcoders] Re: has anyone ever disabled selectability for a textArea?? > package > { > import mx.controls.TextArea; > > class MyTextArea extends TextArea > { > protected override function createChildren():void > { > super.createChildren(); > textField.selectable = false; > } > } > } > > And then use <view:MyTextArea /> instead. Thanks. I think I have this setup properly but now I'm getting a "The prefix "view" for element "view:myTextArea" is not bound" compiler error. Is there something I'm missing so Flex can recognize my new class? The class is packaged in with all of my other .as custom classes. I can include it and recognize it in the Actionscript, but this view command doesn't seem to be working in the mxml. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links ------------------------ Yahoo! Groups Sponsor --------------------~--> Check out the new improvements in Yahoo! Groups email. http://us.click.yahoo.com/7EuRwD/fOaOAA/yQLSAA/nhFolB/TM --------------------------------------------------------------------~-> -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/flexcoders/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/

