Skip to main content
Participant
February 16, 2012
Question

Where do you create objects

Do you always have to create objects on the stage or can you create them in the actual programming. I know you can create a movie clip instance and name it. but can you just inside the programming create a new class and then from there create the instance from the class?

Thanks for all the help i am learning this after doing some C++ so going slow but hopefully will one day be good?

also new to forum. i Don't know if im doing it wrong. I have seen people complain about new people posting stuff in the wrong places.Sorry if i am doing that

This topic is closed to new replies. Start a new post to keep the conversation going.

2 replies

Colin Holgate
Inspiring
February 16, 2012

The forum is meant to be geared towards people who know Flash and are trying to solve a mobile specific thing, so there may be better forums for more general ActionScript questions.

Meanwhile, you can set things in the library to be shared for ActionScript, and give them a Class name. Then when you want one of those, you say something like:

var aWidget:Widget = new Widget();

Translate
Inspiring
February 16, 2012

AS3 is fully object oriented.

You will find tons of examples out there as to how to leverage the OO power of the language.

http://www.adobe.com/devnet/actionscript/articles/oop_as3.html

Some good books that will show you :

- Hello Flex 4 (read first)

- Developing Flex 4 components (read second)

Good luck.

Translate