Re: [flexcoders] Re: Apparent data value change in Advanced DataGrid
Amy, Thanks for the advice. I'm very new to the ADG, and as you well know, it has quirks. Put a break point into a handler for the event when the row is opened, then look in the variables window to see if the data has actually changed. If it has, then you'll need to work backward from there to see how and why. I've attempted to do this, creating a function first assigned to the itemOpening attribute of the ADG, then later to the itemOpen attribute. In neither case does the function appear to be called. There's a breakpoint, but it's never reached. Am I missing something? Nevertheless, I put a bogus button in place so I could fire an event that would let me look at things before and after the tree was opened. And things have gotten even weirder. Yes, the underlying data is changing. The Status is actually being changed within the array collection. Worse yet, it's being changed to a value that does not exist anywhere within the array collection. My test has two groups: in one set of grouped data, the Status is Approved; in the second, the Status is Denied, When I open the tree, the Status displays Pending. When I examine all the variables within the component before the tree is expanded, that string appears nowhere. Nowhere. So clearly, it's being injected from somewhere else. Not from the server, because Charles shows no activity. Something inside the app - but outside the component - is changing the array collection. Until I can find that, I don't think anyone can help. But I appreciate the attempt. -- Thanks, Tom Tom McNeer MediumCool http://www.mediumcool.com 1735 Johnson Road NE Atlanta, GA 30306 404.589.0560
Re: [flexcoders] Re: Apparent data value change in Advanced DataGrid
Hi Amy, On Wed, Oct 21, 2009 at 3:29 PM, droponrcll amyblankens...@bellsouth.netwrote: In your example data, you _did_ have Pending in the second grouping. If your ADG is editable, the possibility is that your retained value is somehow triggering an edit on the wrong item. That's correct. I did, in my original post. However, I continued to test. And one of the things I did was to change to the underlying contents of the data collection (the actual database values) so that no status of Pending would appear. I confirmed through Charles that no Pending status appeared in the incoming data. I confirmed prior to opening a grouping that no item with the string Pending existed anywhere within the component, in an object or collection. I opened a grouping, saw Pending and confirmed that the Status value had changed in both the grouping collection and the underlying array collection. And the datagrid is not editable. So the value is being pushed in from outside somehow. And the trigger is the opening of a grouping. Did you try changing to getItemAt? If so, what was the result? Yes, I did, thanks, before trying anything else. There was no change. And now, after seeing that the data source is what changed, that doesn't surprise me. I just need to find where the data is being pushed from and how. It truly makes no sense, because the array collection contents are simply pulled from a remote object and injected into the view component. As far as I can tell, nothing else ever interacts with the array collection from outside the view. And nothing _inside_ the view contains that particular string. -- Thanks, Tom Tom McNeer MediumCool http://www.mediumcool.com 1735 Johnson Road NE Atlanta, GA 30306 404.589.0560