goaganesha
Programmer
Hi there,
I have a site in which I want to load different movies like cascading windows.
In my main movie I have defined a variable "top". When I load a new window(read swf) by clicking a button, the level to which the new window is loaded is defined as _root.top+1 to make shure the new window is always on the top level. These windows are also dragable. My problem is that when more than 1 window is loaded on top of another, and i want to drag the top window, for some reason the window which was loaded first (and isn't on the top level) is being dragged. therefor I only want the windows to be draggable if they are on the top level.
I tried it by using this code:
if (this._level == _root.top)
{
if ((_root._xmouse < boundsd.xMax) && (_root._xmouse > boundsd.xMin) && (_root._ymouse < boundsd.yMax) && (_root._ymouse > boundsd.yMin))
{
startDrag(_root.venstertje,false,242,250,518,268);
}
}
But somehow _root.top is undefined for the window when it is loaded. So my question is if it is possible to access a variable in my main movie from a loaded movie?
regards, goaganesha
I have a site in which I want to load different movies like cascading windows.
In my main movie I have defined a variable "top". When I load a new window(read swf) by clicking a button, the level to which the new window is loaded is defined as _root.top+1 to make shure the new window is always on the top level. These windows are also dragable. My problem is that when more than 1 window is loaded on top of another, and i want to drag the top window, for some reason the window which was loaded first (and isn't on the top level) is being dragged. therefor I only want the windows to be draggable if they are on the top level.
I tried it by using this code:
if (this._level == _root.top)
{
if ((_root._xmouse < boundsd.xMax) && (_root._xmouse > boundsd.xMin) && (_root._ymouse < boundsd.yMax) && (_root._ymouse > boundsd.yMin))
{
startDrag(_root.venstertje,false,242,250,518,268);
}
}
But somehow _root.top is undefined for the window when it is loaded. So my question is if it is possible to access a variable in my main movie from a loaded movie?
regards, goaganesha