Question
Pass parameters to a movieclip
I call new movie clip with
initObj = new Object()
initObj.recording = recording;
initObj.motionDetection = motionDetection;
initObj.timeRecord = timeRecord;
_root.attachMovie("recordWindow","recordWindow_mc",_root.getNextHighestDepth(),{_x: 0, _y: 0}, initObj);
Now in the code for the recordWindow movieclip I want to get the values I passed via initObj.
Do I need an onLoad function? Would it contain these lines of code to get the parameter values passed to the movieclip?
var motionDetection:Boolean = initObj.motionDetection;
var timeRecord:Boolean = initObj.timeRecord;
var recording:Boolean = initObj.recording;
Yours,
David
initObj = new Object()
initObj.recording = recording;
initObj.motionDetection = motionDetection;
initObj.timeRecord = timeRecord;
_root.attachMovie("recordWindow","recordWindow_mc",_root.getNextHighestDepth(),{_x: 0, _y: 0}, initObj);
Now in the code for the recordWindow movieclip I want to get the values I passed via initObj.
Do I need an onLoad function? Would it contain these lines of code to get the parameter values passed to the movieclip?
var motionDetection:Boolean = initObj.motionDetection;
var timeRecord:Boolean = initObj.timeRecord;
var recording:Boolean = initObj.recording;
Yours,
David
