Link to home
Start Free TrialLog in
Avatar of ugeb
ugebFlag for United States of America

asked on

creating components tutorial?

Hi,

Can anybody point me towards a thorough tutorial on creating components in Flash (or Flex Builder -- not mxml, just as3)?  I've looked around and found a couple of sites, but either they weren't complete or the files weren't readable.  I don't like the Adobe tutorial either.

Two parts in particular I'm looking for clarification for are how to expose variables as parameters and how to publish it so that it can be loaded as a component.

Thanks!

Avatar of IqAndreas
IqAndreas
Flag of Sweden image

I believe you are looking for "Learning how to create classes in AS3"

Basically, components are classes. Classes are just a more general name, while components are classes that you can place directly onto the stage.

Here are a few links to get you started, and if you need more tutorials, just ask. I will also gladly explain any questions you have along the way.

http://www.kirupa.com/developer/as3/classes_as3_pg1.htm
http://www.flashandmath.com/bridge/intro/index.html
For more results: http://www.google.se/#q=as3+class+tutorial

Good luck with your programming,
Andreas
Avatar of ugeb

ASKER

No, I'm sorry but you are not correct.  I've been doing OOP programming for 15 years and have degrees in CS.  

I am needing specific tutorials on components, hot classes.  Creating classes is easy.  Creating components requires other steps that I need clarification on.
Sorry about that. I tend to assume that all people who ask questions are beginners. ;)

In ActionScript 3, components are classes that extend things like InteractiveObject (among other classes) so they can capture user input. You are talking about components such as "Buttons", "TextAreas", "Sliders" etc, correct?

Components in the mx.* package do not need to be imported via MXML. They can be imported with pure ActionScript. MXML is just a shorthand for designers to create components, but when the SWF compiles, all that MXML turns into regular ActionScript.

Could you elaborate a little more on what exactly you are looking for?

Do you want to export components to SWC format so they can be used like other SWC components?
Do you want to create components with bindable properties and events?
Do you want to add skinning capabilities to them?


Someone asked a similar question to yours recently on the Kirupa forums with several great replies, but for the life of me, I cannot find it again. However, if I track it down, I will reply back with the link.

Is there any reason you don't want to use any of Adobe's tutorials? The Flex in a Week video series was very informative, and I believe you would find a great deal of information on components there.
http://tv.adobe.com/show/flex-in-a-week/

I am also in the process of compiling a list of available flash component suites, and the list might be of some use to you. http://www.kirupa.com/forum/showthread.php?t=343020
I think I see now.

Do you want to create components that can be dragged from the Flash Professional Components window onto the stage rather than be instantiated via pure ActionScript?

Perhaps this guide is of some use to you:
http://www.adobe.com/devnet/flash/articles/creating_as3_components.html

I can keep looking if that does not answer all your questions. And feel free to ask if there is anything I can help clarify.
ASKER CERTIFIED SOLUTION
Avatar of IqAndreas
IqAndreas
Flag of Sweden image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of ugeb

ASKER

Not exactly what I was hoping for, but I'll make do.  Thanks.