all groups > flash actionscript > january 2007 >
You're in the

flash actionscript

group:

Error: A 'with' action failed because the specified object did not exist.


Error: A 'with' action failed because the specified object did not exist. Mangesh1987
1/1/2007 4:20:50 PM
flash actionscript:
Error: A 'with' action failed because the specified object did not exist.

this error comes when I run my clients 'youtube.fla' file

the object is defined .

then why this message comes.

can anyone help me?

Mangesh Shinde
Re: Error: A 'with' action failed because the specified object did not exist. kglad
1/1/2007 5:27:06 PM
Re: Error: A 'with' action failed because the specified object did not exist. Mangesh1987
1/1/2007 5:40:23 PM
I have done that, but it shows the same error again

class as.Controller extends MovieClip
{

//reference to the top movie
private var movie:MovieClip;

private var left_bg, main_bg, right_bg:MovieClip;
private var pause_button, play_button, stop_button:Button;
private var full_progress_bar, slider, fullBar, seekBar,
progressBar:MovieClip;
private var fullpbar_b_width = 138;
private var movie_b_width = 450;
private var left_xstart:Array;
private var right_xstart:Array;

private var ldiv, mrdiv, rdiv, regular, small, min, max;

private var slider_start_pos:Number;
private var slider_down:Boolean;

//show's time
private var timer:MovieClip;

private var sound_control:MovieClip;

//when file's playing
private var file_playing:MovieClip;

private var WAS_END:Boolean;

var left_justified_elements;
var right_justified_elements;

private function setTime()
{
timer.seek_time.text = movie.getTime();
}

private function setTotalTime()
{
timer.seek_total_time.text = movie.getTotalTime();
}

private function getScale()
{
var _loc2 = (slider._x - full_progress_bar._x) /
full_progress_bar._width;
if (_loc2 < 0)
{
return (0);
}
else
{
return (_loc2);
} // end else if
} // End of the function

private function filePlaying()
{
var _this = this._parent;
with (_this)
{
var time_pos=0;

if(movie.getTimePos()>0 && movie.getTimePos()!=Infinity)
time_pos = movie.getTimePos();

slider._x = time_pos * full_progress_bar._width + full_progress_bar._x;

setTime();

setTotalTime();

progressBar._width = movie.getLoadRatio()*fullBar._width;
seekBar._width = movie.getTimePos() * fullBar._width;;//slider._x+143.3;


with(_parent.movie)
{
if(getTimeNumber()<2)
WAS_END = false;

if(
timer.seek_time.text!="00:00"
&&
timer.seek_time.text==timer.seek_total_time.text
//getTotalTimeNumber() - getTimeNumber() <1 &&
// getTotalTimeNumber() - getTimeNumber() >0 &&
&&
!WAS_END
)
{
movieEnds();

if(_parent.auto_reset_playhead=="true")
{
stop_button.onRelease();

if(_parent.LOOPING=="false")
{
pause_button.onRelease();
}
}
//else
//pause_button.onRelease();

WAS_END = true;
}
}
}
}

function Controller()
{
var o = this;


play_button._visible = false;
pause_button._visible = true;

slider_start_pos = new Number();
slider_start_pos = slider._x;

slider_down = new Boolean();
slider_down = false;

movie=this._parent.movie;
movie.onPlay = function ()
{
o.play_buttonRelease();
}
movie.onStop = function ()
{
o.pause_buttonRelease();
}
movie.onSeek = function (ir)
{
o.showSeek(ir);
};


var o = this;

play_button.onRelease = function ()
{
o.play_buttonRelease();
o.movie.playMovie();
};
pause_button.onRelease = function ()
{
o.pause_buttonRelease();
o.movie.pauseMovie();
};
stop_button.onRelease = function ()
{
o.movie.stopMovie();
o.slider._x = o.slider_start_pos;
};

var _loc6 = function ()
{
o.slider_down = true;
o.slider.highLight();

o.onEnterFrame = function ()
{
var _loc1 = _xmouse;

//o._parent.test_txt.text = full_progress_bar._xscale;

if (_loc1 < full_progress_bar._x)
{
_loc1 = full_progress_bar._x;
}
else if (_loc1 > full_progress_bar._x +
full_progress_bar._width)
{
_loc1 = full_progress_bar._x + full_progress_bar._width;
} // end else if
slider._x = _loc1;
movie.peekSeekRatio(getScale());
} // End of the function
};
var _loc7 = function ()
{
o.slider.normal();
o.slider_down = false;
delete o.onEnterFrame;
};

full_progress_bar.onPress = slider.onPress = _loc6;
full_progress_bar.onRelease = full_progress_bar.onReleaseOutside =
slider.onRelease = slider.onReleaseOutside = _loc7;

file_playing = this.createEmptyMovieClip("file_playing",
this.getNextHighestDepth());
file_playing.onEnterFrame = this.filePlaying;

WAS_END = new Boolean();
WAS_END = false;

//creating movies with graphs
progressBar.createEmptyMovieClip("graph", 5);
full_progress_bar.seekBar.createEmptyMovieClip("graph2", 6);
main_bg.createEmptyMovieClip("graph", 6);
left_bg.createEmptyMovieClip("graph", 6);
right_bg.createEmptyMovieClip("graph", 6);
sound_control.bg_mc.createEmptyMovieClip("graph", 6);

main_bg.graph._alpha=13;
left_bg.graph._alpha=13;
right_bg.graph._alpha=13;

left_justified_elements = [play_button, pause_button, stop_button, ldiv,
full_progress_bar];
right_justified_elements = [timer, mrdiv, sound_control, rdiv, regular,
small, min, max];

var bounds = this.getBounds(this);
left_xstart = new Array();

left_xstart.push(-69.7);
left_xstart.push(-31.9);
left_xstart.push(-33.7);
left_xstart.push(-3.69999999999999);
left_xstart.push(-3.69999999999999);

right_xstart = new Array();

right_xstart.push(30.3);
right_xstart.push(54.85);
right_xstart.push(54.5);
right_xstart.push(54.5);
right_xstart.push(65);
right_xstart.push(148);
right_xstart.push(157);
right_xstart.push(232);

var k=0;
for (var i in left_justified_elements)
{
left_justified_elements[i]._xstart =
left_xstart[k++];//bounds.xMin - left_justified_elements[i]._x;


//trace("left_xstart.push(" + left_justified_elements[i]._xstart+");");
}

k=0;
for (var i in right_justified_elements)
{
right_justified_elements[i]._xstart =
right_xstart[k++];//bounds.xMax - right_justified_elements[i]._x;

//trace("right_xstart.push(" + right_justified_elements[i]._xstart+");");
}

//resizing a video
regular.onPress = function ()
{
o.movie.resizeNormal();
o.regular._visible = false;
o.small._visible = true;
};
small.onRelease = function ()
{
o.movie.resizeOriginal();
o.regular._visible = true;
Re: Error: A 'with' action failed because the specified object did not exist. kglad
1/1/2007 5:44:07 PM
Re: Error: A 'with' action failed because the specified object did not exist. Bird B.
1/10/2007 11:46:38 AM
Re: Error: A 'with' action failed because the specified object did not exist. kglad
1/10/2007 8:25:07 PM
AddThis Social Bookmark Button