I could not get your problem exactly, but is this what you are looking for?

//The document class
package
{
import flash.display.MovieClip;
public class myClass extends MovieClip
{
 public static var myArr:Array=[1,2,3];
 private var myC2 = new myClass2
 function myClass()
 {
  sendArrays()
 }
 function sendArrays()
 {
  var someArr = [5,6,7]
  myC2.getArrays(myArr,someArr)
 }
}
}

// the other class
package
{
import flash.display.MovieClip;
public class myClass2 extends MovieClip
{
 function myClass2()
 {
 }
 function getArrays(a,b)
 {
  trace("hey = "+a)
  trace("hey2 = "+b)
 }
}
}

If this is not what you are looking for, could you explain your question a bit more in detail?

thanks

----- Original Message ----- From: "Carl Welch" <[EMAIL PROTECTED]>
To: "Flashcoders mailing list" <flashcoders@chattyfig.figleaf.com>
Sent: Thursday, July 27, 2006 12:39 PM
Subject: [Flashcoders] pass variables between classes in AS3


I have an AS3 document class where I load and parse an xml file into
an array. I would like to pass that array to a movieclip(?) class -
basically its a button that will create new movieclips that will
differ based on my xml array. How in the world do I get the array from
the document class to other classes... arggg! as3 is blowing my mind.
I've googled but I can't find anything that make sense to my as2
brain.

Thanks again.

--
Carl Welch
http://www.carlwelch.com
[EMAIL PROTECTED]
805.403.4819
_______________________________________________
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