3 Replies Latest reply on Jun 13, 2008 7:35 AM by kglad

    concat empty list

    Level 7
      Hi,

      I have a problem with concat and empty lists. Instead of adding nothing
      to an existing list concat adds the value undefined to the existing list.

      ...
      _global.areaList [n] = []
      testlist.concat(_global.areaListRange [n] );
      trace("testlist " + testlist[testlist.length])
      trace("_global.areaList [" + n + "] = " + _global.areaList [n].length)
      ..

      my traces give me values like this:
      //
      _global.areaList [0] = 0
      testlist undefined


      Is there a short alternative command _not_ to add "undefined" to my
      list? I want to prevent another if-condition because the function where
      I use this is made for performance reasons.

      TIA