I just posted a message about AS3 because I am trying to learn 3DFA and it was deleted. Should I repost or was it deleted deliberately?
Printable View
I just posted a message about AS3 because I am trying to learn 3DFA and it was deleted. Should I repost or was it deleted deliberately?
I see one as3 question you posted... forum seems to be defaulting to "show last day"... so is it just slipped "out" of default view and not deleted??
No messages have been deleted that i know of, but Flashkit seems to be acting a little unusual lately.
Ok I have this class entered into a program in 3DFA with flash 9 export:
package {
import flash.display.Sprite;
import flash.utils.setInterval;
public class SetIntervalExample extends Sprite {
private var intervalDuration:Number = 1000; // duration between intervals, in milliseconds
public function SetIntervalExample() {
// var intervalId:uint = setInterval(myRepeatingFunction, intervalDuration, "Hello", "World");
trace("SetIntervalExample called");
}
public function myRepeatingFunction():void {
trace(arguments[0] + " " + arguments[1]);
}
}
}
and am trying to activate it with a script:
var xx:SetIntervalExample = new SetIntervalExample;
xx.SetIntervalExample();
No matter how I do this I cannot seem to get the program to recognize the setInterval function. It keeps saying setInterval is not a method of the SetIntervalExample class or other messages depending.
Anyone know why?
I think your Post still exist: http://board.flashkit.com/board/showthread.php?t=768446
Change the display options on the bottom to see all posts:
http://upload.picturevz.de/LewxX/display_options.jpg
First, I see no such option to change display. Perhaps it is the level of user? Second in the sample code I posted this line causing the problem:
// var intervalId:uint = setInterval(myRepeatingFunction, intervalDuration, "Hello", "World");
was NOT commented out during my various trials. I neglected to change it back by accident.
You mean this message - here?
Nothing's been deleted.
LewxX² got it right the first time. Under your name, richinri, nothing has been deleted.
Yes, I changed the setting and see more messages now. But does anyone have the answer?
I see what is happening now. Everytime I leave the forum the settings go back to one day's listings. I marked the other message resolved so this thread can continue. Does anyone know why the code I submitted in this thread won't work?
Quote:
Originally Posted by richinri
To simplify here is the code again in a class file:
package {
import flash.display.Sprite;
import flash.utils.setInterval;
public class SetIntervalExample extends Sprite {
private var intervalDuration:Number = 1000; // duration between intervals, in milliseconds
public function SetIntervalExample() {
var intervalId:uint = setInterval(myRepeatingFunction, intervalDuration, "Hello", "World");
trace("SetIntervalExample called");
}
public function myRepeatingFunction():void {
trace(arguments[0] + " " + arguments[1]);
}
}
}
And the script to run it in a script file:
var xx:SetIntervalExample = new SetIntervalExample;
xx.SetIntervalExample();
trace(typeof(xx));
gives the error message that setInterval is not a function of the SetIntervalExample class.
The AS3 book I am trying to learn this program with says it should work fine.
I'm sorry, but you've already lost me, I'm not the best bay far...
Zoranan