Sunday, March 28, 2010

import mx component into AS class

Hello, I am trying to import an MXML custom component into an Actionscript class.

It wont let me.

Is this possible, or can you only import other AS-Flex extended classes into an AS class ?

eg

my folder/file structure is as follows:

?mainFlexApp

?CustomMXComponents?CustomASClasses

myCustomMXMLComponent?myCustomASClass

I need to import myCustomMXMLComponent into myCustomASClass.

myCustomMXMLComponent being a pure MXML component.

Thanks for any help.

import mx component into AS class

try this

import yourfolder.myCustomMXMLComponent;

public class myCustomASClass extends myCustomMXMLComponent

{

...

--

Leonardo Fran鑾絘

Adobe Certified Expert Flex 3 with AIR

Adobe Certified Expert Rich Internet Application Specialist v1.0

Adobe Certified Expert Flash CS3 Professional

Certified Professional Adobe Flex 2 Developer

Adobe Certified Professional Flash MX 2004 Developer

http://www.leonardofranca.com

http://twitter/leofederal

Manager AUGDF - Adobe User Group do Distrito Federal

http://www.augdf.com.br

http://twitter/augdf

phil1943 escreveu:

Hello, I am trying to import an MXML custom component into an Actionscript class.

It wont let me.

Is this possible, or can you only import other AS-Flex extended classes into an AS class ?

eg

my folder/file structure is as follows:

%26amp;n bsp; mainFlexApp

CustomMXComponents %26amp; nbsp; CustomASClasses

myCustomMXMLComponent %26amp;nbsp ; myCustomASClass

I need to import myCustomMXMLComponent into myCustomASClass.

myCustomMXMLComponent being a pure MXML component.

Thanks for any help.

%26gt;

No comments:

Post a Comment