I also do have same kind of problem. But I never tried to
  refresh the array collection. I tied a button to the Httpservice
  and once the array is populated if you press the button,
  which send the httpservice request, all the data disappear.
  Now if you press the button second time, that means send the
  httpservice request second time, the data shows up with
  the updated values.

  I guess what Alex said is happening in my case. When I first
  press the button, httpservice returns an empty arraycollection,
  but when the button is pressed the second time it returns the
  updated array. But one thing I do not understand- why would
  it return empty arraycollection? When I coded I expected it to
  remove all the elements from the array collection and the put
  the new httpservice request's return result!!!!


--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> I would think that your service should return an empty array collection,
> or return a failure.  If it returns an empty array collection it should
> refresh.  If it returns a failure, then you should set the
> arraycollection to an empty arraycollection on failure
> 
>  
> 
> ________________________________
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of jovialrandor
> Sent: Saturday, April 05, 2008 9:16 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] How can I clear an ArrayCollection or Datagrid
> 
>  
> 
> I use a HTTPService to load data into an ArrayCollection which is used 
> for a datagrid. For example I type in a parameter A to the 
> HTTPService that returns data that gets loaded in to ArrayCollectin.
> 
> However when I when resend the HTTPservice with parameter B that 
> returns no data, the datagrid still displays the value of parameter A.
> 
> I've tried:
> 
> httpservice.send(); // To get new values
> arraycollection.refresh(). // To refresh the datagrid.
> 
> But no luck.
> 
> Thanks
>


Reply via email to