I'm a little dyslexic :-), I meant itemUpdated()
--- In flexcoders@yahoogroups.com, Sherif Abdou <[EMAIL PROTECTED]> wrote: > > mainApp.myAC. updateItem( ) where are you getting the updateItem() method from? there is no updateItem() method in the collection, best stradgey for this i would think is so just use the setItemAt() and getItemAt(); > m.setItemAt(newItem,m.getItemAt(oldItem)) > > > > ----- Original Message ---- > From: jmfillman <[EMAIL PROTECTED]> > To: flexcoders@yahoogroups.com > Sent: Saturday, January 19, 2008 8:35:59 PM > Subject: [flexcoders] Update ArrayCollection from PopUp TitleWindow > > I've found it amazingly easy to add an item to an ArrayCollection > from a PopUp window: > > var newItem:Object = {date: myDate.id, height: myHeight, subject: > mySubject.text, notes: myNotes.text} ; > mainApp.myAC. addItem(newItem) ; > > However, when it comes to updating that item from a PopUp, it appears > to be amazingly difficult (so difficult that I can't figure it out!). > > mainApp.myAC. updateItem( ) doesn't seem to be possible from the PopUp, > in fact, I can't even do: > > trace (mainApp.myAC. length); > > This throw the common "Cannot access a property or method of a null > object reference" error. > > I haven't tried it yet, but all I've found that looks like a > possibility, is to create variables in the parent, set those from the > PopUp, and then run a function to perform updateItem() , for each > value in the ArrayCollection row OR, delete the row, and add a new > one. Both create issues with sychronizing front-end display items and > backend databases. > > Please help > > > > > > ______________________________________________________________________ ______________ > Looking for last minute shopping deals? > Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping >