Welcome, Guest
  • Author Topic: why don't get it?  (Read 1076 times)

    NhocTi

    • Server what's that
    • *
    • Posts: 44
      • View Profile
      • Email
    why don't get it?
    « on: 09/27/04, 21:33 »
    use this code
    trace(datagird.content_mc.lines_mc.type);

    why datagrid.content_mc.lines_mc is undefined i have view in DataGrid.as and it show that

    //:::Movie clip assets
    var lines_mc : MovieClip;      // the movie clip in which grid lines are drawn

    please help me how to get lines_mc movieclip.
    thanks

    Jorge Solis

    • Global Moderator
    • Systems Administrator
    • *****
    • Posts: 14616
      • View Profile
    Re:why don't get it?
    « Reply #1 on: 09/28/04, 03:56 »
    Datagrid is a component with methods and properties, none of them named content_mc. I think you have some conceptual mess, or ...?

    Jorge

    NhocTi

    • Server what's that
    • *
    • Posts: 44
      • View Profile
      • Email
    Re:why don't get it?
    « Reply #2 on: 09/28/04, 05:02 »
    use that code
    for (a in datagird)
    {
       trace(a);
    }

    you will see once instance name : content_mc
    and when u use

    for (a in datagrid.content_mc)
    {
      trace(a);
    }

    you see once instance name : lines_mc

    :)

    Jorge Solis

    • Global Moderator
    • Systems Administrator
    • *****
    • Posts: 14616
      • View Profile
    Re:why don't get it?
    « Reply #3 on: 09/28/04, 05:11 »
    Yep, but classes in V2 arquitecture have accesors to acces public properties (and methods), you can't acces private members from outside.

    Jorge

    NhocTi

    • Server what's that
    • *
    • Posts: 44
      • View Profile
      • Email
    Re:why don't get it?
    « Reply #4 on: 09/28/04, 19:43 »
    thanks, 'll try to add some code to DataGrid.