Dang,

You got me excited with:

[ArrayElementType("cairngorm.vo.FriendVO")]
public var friends:ArrayCollection;

But, according to the docs, this only applies to type: Array. I tried it
and compiler does not appear to pick up on this restriction, for
ArrayCollection (I tried adding item not of type in [ArrayElementType()] and
it threw no errors).

-Scott



On 2/14/07, martywolf11 <[EMAIL PROTECTED]> wrote:

  hello,

In my ModelLocator class i defined an ArrayCollection:

[Bindable]
[ArrayElementType("cairngorm.vo.FriendVO")]
public var friends:ArrayCollection;

storying the FriendVO object works perfectly, but now i want an event
to fire up whenever i add a new FriendVO object, delete it or change it.
i just tried to use the following command for that:

MyModelLocator.getInstance().friends.addEventListener(
CollectionEvent.COLLECTION_CHANGE,createFriendsList);

which should invoke the method createFriendsList()

private function createFriendsList():void
{ Alert.show("create friendslist"); }

but it is never called, not even when i do
MyModelLocator.getInstance().friends = new ArrayCollection();

can anybody tell me what i am doing wrong?
i really would appreciate any info.

thanks,

marty




--

: : ) Scott

Reply via email to