Action-Script created MC 's -> path

I really don’t know what the problem is here.
The trace() function only gives me “0” as the output.
I want to be able to reach the objects created and delete and change their _x and _y positions and all kinds of stuff. But it seems i can’t even get the _width value.

[AS]/*

  • Creates a new news box for the calender
    */
    _global.createNewsFrame = function(f_x,f_y,f_width,f_height,name)
    {
    MC_obj = _root.createEmptyMovieClip(name, 1);
    with (_root[name])
    {
    beginFill (0xc0c0c0, 100);
    lineStyle (1, 0x000000, 100);
    moveTo (f_x, f_y); //1
    lineTo (f_x + f_width, f_y); //2
    lineTo (f_x + f_width, f_y + f_height); //3
    lineTo (f_x, f_y + f_height); //4
    endFill();
    }
    return MC_obj;
    }

rect1 = createNewsFrame(0,0,300,300,rect1);
rect2 = createNewsFrame(306,0,300,300,rect2);

trace(_root.rect2._width);[/AS]

maybe created mc’s always have 0 width??? (dont know)

maybe instead u should handle _xscale

could be a result of the invalid names (that is unless rect1 and rect2 are variables containing the names you want)