Hi G,

"slice" is an ArrayCollection or Object (depending on the result 
format), not an Array.  Therfore, the slice() method isn't 
available.  You could either filter the ArrayCollection, loop 
through it, or cast explicitely.

slicedResults.push(results[1].label);
slicedResults.push(results[3].label);

-TH

--- In [email protected], "g_vaccarezza" <[EMAIL PROTECTED]> wrote:
>
> Hi guys
> 
> I got this :
> 
> <mx:Model id="results">
>       {myData.lastResult.data.month} 
> </mx:Model>
> 
> If I:
> 
> trace (results[3].label)  // Yields April, cool
> 
> But If I:
> 
> private function sliceResults(): void {
>    [Bindable] public var slicedResults: Array = new Array();
>    slicedResults = results.slice(1,3)
>    trace (slicedResults.toString); 
> }
> 
> I compile the mxml, and when I call the function, I get the 
following 
> output error:
> 
> Error: Unknown Property: 'slice'. 
> 
atmx.collections::ListCollectionView/http://www.adobe.com/2006/action
s
> cript/flash/proxy::getProperty()...bla bla bla
> 
> Any ideas what this could be? Isn't results supposed to be an 
array?
> 
> Help me out! thanks!
> -g
>






--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/flexcoders/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:[EMAIL PROTECTED] 
    mailto:[EMAIL PROTECTED]

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to