import in AS2, is to help you avoid typing in the complete package name
everytime u reference a class.

The following code

import mx.controls.Button;
var playBtn:Button;
.......
var stopBtn:Button;
........
var pauseBtn:Button;

will look like this:

var playBtn:mx.controls.Button;
.......
var stopBtn:mx.controls.Button;
........
var pauseBtn:mx.controls.Button;

if you don't use an import.

Please refer flash help for more details..

:)
~Arul Prasad

On 5/25/06, Rifled Cloaca <[EMAIL PROTECTED]> wrote:

Flashcoders,

So this is one of those things I wonder about.  If I type a var to a
custom
type, doesn't the compiler automatically import the associated class
files?
When or why would I need to explicitly need to use the import directive?

Thanks in advance!
-g
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to