Hi there!

I have a little problem i can’t solve myself.

I have a main MC called container_mc.
container_mc has two mc’s called thumb_mc and detail_mc
for every xml record i’ve got there will be a thumb_mc
easy so far…

when pressing a thumb in detailview there will be all the data from the xml.

The title of the project, the description, year, type and a bigger movie will be loaded.
This all works fine butt… a added a link also. i call it on the same way as all the other ChildNodes with this.link where this is this xml-record and link is the variable opf the link
It works with everything the title, the big movie and the text all but when clicking on the view project button i’ll have a undefined! does someone can help me? please!?:b:

here is the code i use:



detailView._alpha = 0;

//

var newXML:XML = new XML ();

newXML.ignoreWhite = true;

newXML.load ('include/xml/projects_xml.php');

tmb._visible = false;

////////////////////////////////////////////////////////////

newXML.onLoad = function ()

{

    var childs:XMLNode = newXML.firstChild;

    var childTotal:Number = childs.childNodes.length;

    _global.fcn = function ()

    {

        for (var i = 0; i < childTotal; i++)

        {

            if (i != selected)

            {

                _parent.container['tmb' + i].enabled = true;

                _parent.container['tmb' + i].useHandCursor = true;

                _parent.container['tmb' + i].bg.alphaTo (100, 1);

            }

        }

    };

    for (var i = 0; i < childTotal; i++)

    {

        tmb.duplicateMovieClip ('tmb' + i, _parent.container.getNextHighestDepth ());

        ////////////////////////////////////////////////////////////

        _parent.container.tmb0.enabled = true;

        _parent.container.tmb0.useHandCursor = true;

        _parent.container.tmb0.alphaTo (100, 1);

        ////////////////////////////////////////////////////////////

        var pProject = (childs.childNodes*.childNodes[0].firstChild.nodeValue);

        var pcustomer = (childs.childNodes*.childNodes[2].firstChild.nodeValue);

        var pType = (childs.childNodes*.childNodes[3].firstChild.nodeValue);

        var pyear = (childs.childNodes*.childNodes[4].firstChild.nodeValue);

        var pLink = (childs.childNodes*.childNodes[5].firstChild.nodeValue);

        var pTmb = (childs.childNodes*.childNodes[6].firstChild.nodeValue);

        var pSwf = (childs.childNodes*.childNodes[7].firstChild.nodeValue);

        var pDescript = (childs.childNodes*.childNodes[8].firstChild.nodeValue);

        ////////////////////////////////////////////////////////////

        _parent.container['tmb' + i].box.loadMovie (pTmb);

        ////////////////////////////////////////////////////////////

        _parent.container['tmb' + i].pProject = pProject;

        _parent.container['tmb' + i].pcustomer = pcustomer;

        _parent.container['tmb' + i].pType = pType;

        _parent.container['tmb' + i].pyear = pyear;

        _parent.container['tmb' + i].pLink = pLink;

        _parent.container['tmb' + i].pTmb = pTmb;

        _parent.container['tmb' + i].pSwf = pSwf;

        _parent.container['tmb' + i].pDescript = pDescript;

        ////////////////////////////////////////////////////////////

        var thmb = _parent.container['tmb' + i];

        thmb._x = i % 4 * 66;

        thmb._y = Math.floor (i / 4) * 66;

        ////////////////////////////////////////////////////////////

        _parent.container['tmb' + i].onRollOver = function ()

        {

            this.box.alphaTo (80, 1);

            _root.tmbSound.start (0, 1);

        };

        _parent.container['tmb' + i].onRollOut = function ()

        {

            this.box.alphaTo (100, 2);

        };

        _parent.container['tmb' + i].onPress = function ()

        {

            _global.selected = this.i;

            this.enabled = false;

            this.useHandCursor = false;

            fcn ();

        };

        _parent.container['tmb' + i].onPress = function ()

        {

            detailView.alphaTo (100, .5);

            var project = detailView.projectname;

            project.htmlText = this.pProject;

            project.html = true;

            project.autoSize = false;

            //

            var customer = detailView.customername;

            customer.htmlText = "CUSTOMER. <font color='#ffffff'>" + this.pcustomer + "</font>";

            customer.html = true;

            customer.autoSize = false;

            //

            var typetxt = detailView.typetxt;

            typetxt.htmlText = "CATEGORY. <font color='#ffffff'>" + this.pType + "</font>";

            typetxt.html = true;

            typetxt.autoSize = false;

            //

            var year = detailView.year;

            year.htmlText = "YEAR. <font color='#ffffff'>" + this.pyear + "</font>";

            year.html = true;

            year.autoSize = false;

            //

            var txt = detailView.Description.txt;

            txt.htmlText = this.pDescript;

            txt.html = true;

            txt.autoSize = true;

            //

            var view_project_mc = detailView.view_project_mc;

            view_project_mc.onRollOver = function ()

            {

                view_project_mc.txt_mc.colorTo (0xFFFFFF);

            };

            //

            view_project_mc.onRollOut = function ()

            {

                view_project_mc.txt_mc.colorTo ();

            };

            //

            view_project_mc.onRelease = function ()

            {

                getURL ("" + this.pLink + "", "_blank");

            };

            //

            var box = detailView.imgMc.clip.box;

            box.loadMovie (this.pSwf);

            //

            var slid = detailView.imgMc.player.slid;

            var img = detailView.imgMc;

            slid._x = 0;

            img.gotoAndplay (1);

        };

    }

};