> can have your class in the app folder
> called this looks like it extends a display object

Not exactly :-)
If It extends Sprite, the result is "grey-gradient" standard flex bg,
w/o any traces of my objects. Trace commands are executed nice,
If I make the main class extending mx.core.Application then, in
addition to tracing messages,  I can see my (white) background and
"initializing" progress bar.
[Fault] exception, information=TypeError: Error #1034: Type Coercion
failed: cannot convert mx.core::[EMAIL PROTECTED] to
Fault, addingChild() at
where FlexSprite is used in code:

var triangle:FlexSprite = new FlexSprite( );
// drawing a triangle...

And it's addChild() that causes the error (no error with addChild() commented).

So far, it looks strange for me, as the argument's type of
mx.core.Application.addChild() is DisplayObject.


Glen Pike wrote:
> You can write pure AS3 files for Flex - all MXML gets "compiled
> down" to AS3 before it is compiled to bytecode.
> (I had done followed an example online which has a pure AS3
> component - once it is written, you add the package to your namespace
> and add an MXML tag in your code to add it to the stage.)
> Like with the workaround on the forum you posted - if you have added
> your package path to the namespace ( xmlns:app="app.*"), you can write
> your code in an AS file rather than an MXML file, then you write it as
> you would any other class file - no need for Script tags & mixing mxml /
> as code.
> <?xml version="1.0" encoding="utf-8"?>
> <mx:Application horizontalScrollPolicy="off"
> xmlns:mx=""; xmlns:app="app.*"
> layout="absolute" frameRate="30">
> <app:SystemCore id="sysCore" width="100%" height="100%"/>
> </mx:Application>
> So the above example, you can have your class in the app folder
> called this looks like it extends a display object or
> similar as it has width and height attributes - not sure about extending
> other classes.

Best regards,
Flash components development.
Usability services.
Flashcoders mailing list

Reply via email to