|
<?xml version="1.0" encoding="utf-8"?>
<mx:Canvas
xmlns:mx="http://www.adobe.com/2006/mxml" width="400"
height="300">
<mx:TextInput
textAlign="left" color="green"/>
</mx:Canvas> |
You can use the above component in another mxml file by setting the mxlns
property to the custom component. Here MyComp refers to the any component in
mycomp package.
|
<?xml version="1.0" encoding="utf-8"?>
<mx:Application
xmlns:mx="http://www.adobe.com/2006/mxml"
layout="absolute"
xmlns:MyComp="mycomp.*">
<MyComp:MyMXMLCustomComponent/>
</mx:Application> |
See the output below. Type some text in the input box, you will see green text inside the box.
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.