Hi Giro,

Once initialization has been done which is the case when the click event 
happened, you must use the getRepeaterItem() method of the repeated component 
instance instead of currentItem property.

Hope this helps,

Giro wrote:
> Hi,
> 
>  
> 
> I have this code
> 
>  
> 
> <mx:Repeater id="newRepeater" 
> dataProvider="{newsRequest.lastResult.news.noti}" count="2">
> 
> <mx:Label y="{20+(newRepeater.currentIndex*35)}" 
> text="{newRepeater.currentItem.data}" color="0xcccccc"/>
> 
>             <mx:Label y="{32+(newRepeater.currentIndex*35)}" 
> text="{newRepeater.currentItem.titol}" color="0xffffff" width="200" 
> useHandCursor="true" click="openSite(newRepeater.currentItem.url)" 
> buttonMode="true" mouseChildren="false"/>
> 
>             <mx:Label text="{newRepeater.currentItem.url}" />
> 
> </mx:Repeater>
> 
>  
> 
> All work okay, but when i press Label, error say:
> 
>  
> 
> Error: Repeater is not executing.
> 
>             at mx.core::Repeater/get currentItem()
> 
>             at vidi_new/___Label3_click()
> 
>  
> 
>  
> 
> How i can pass repeater data to a function?
> 
>  
> 
>  
> 
> Thk.
> 
>  
> 
> Giro.
> 
> 


-- 
Christophe

Reply via email to