1 Reply Latest reply on Sep 28, 2008 6:31 PM by manofspirit

    Passing Text From Class to Main Program

    BudHud
      I am trying to write three separate strings from the class file into three separate TEXT boxes within the main program. It works using three separate functions. Is there a way to change the code so it all can happen from within but one and the same function in the class file.

      package Edit
      {
      public class Texter
      {
      public var i:int;
      public static var result:String;

      public function Greeter()
      {
      }
      public function sayHello():String
      {
      result = "This is the first idea I have. ";
      return result;
      }
      public function sayGoodbye():String
      {
      result = "Here is the second idea, like. ";
      return result;
      }
      public function sayHi):String
      {
      result = "Here is the third city disco. ";
      return result;
      }
      }
      }

      Thanks,

      BudHud