Join Date: Sep 2007
Posts: 2
[IMG]http://www.actionscript.org/forums/images/icons/icon1.gif[/IMG] **Calling a function within a class**
Hi I have created a basic class that says hello when the runs but I want to know how to call the sayGoodBye() function with a mouse click on a button or movieclip. The button/movie does not belong to this class
Thanks,
package {
import flash.display.;
import flash.events.;
import fl.transitions.*;
import flash.display.MovieClip;
public class Greetings extends MovieClip
{
public function Greetings()
{
trace('hello');
}
public function sayGoodBye()
{
trace('see ya');
}