0 Replies Latest reply on Nov 8, 2007 1:05 PM by XXIlladelphia

    ArrayCollection.getItemAt()

    XXIlladelphia Level 1
      public function getItemAt(index:int, prefetch:int = 0):Object
      Gets the item at the specified index.

      Returns
      Object — The item at that index, or null if there is none.


      By definition, this is supposed to return null if the item does not exist. When I test (ArrayCollection.getItemAt(invalidIndex) == null) it never returns true. However, if I trace that same index, it will break. How can I know if there is an item at that index or not?