Re: [flexcoders] help with a repeater

2011-10-07 Thread Gustavo Duenas

thanks for your help
here is the error log

Error: Repeater is not executing.
	at mx.core::Repeater/get currentItem()[C:\autobuild\3.3.0\frameworks 
\projects\framework\src\mx\core\Repeater.as:305]
	at iglesiaFls/openWindowVimeo()[/Users/gustavoduenas/Documents/Flex  
Builder 3/iglesiaFls/src/iglesiaFls.mxml:17]
	at iglesiaFls/__vimeoButton_click()[/Users/gustavoduenas/Documents/ 
Flex Builder 3/iglesiaFls/src/iglesiaFls.mxml:51]


On Oct 7, 2011, at 12:47 AM, Tandon, Rishi wrote:



You missed the most important thing in message, the error log.
Send over that.

From: Gustavo Duenas gdue...@leftandrightsolutions.com
To: flexcoders@yahoogroups.com
Sent: Friday, October 7, 2011 9:47 AM
Subject: [flexcoders] help with a repeater


I have a repeater which reads a xmllist from vimeo, it works and do  
the repeat but when I tried to pass info from the repeater to the  
title window, something happens and I have an as3

errror. this is  my code.

mx:Script
![CDATA[
import mx.managers.PopUpManager;
import mx.containers.*;
import mx.controls.Alert;
import mx.rpc.events.FaultEvent;
import mx.rpc.events.ResultEvent;
import flsWindow;

private function openWindowVimeo(event:MouseEvent):void{
var myVimeoWindow:TitleWindow=  
TitleWindow(PopUpManager.createPopUp(this, flsWindow, true));
myVimeoWindow.title=vimeoService.lastResult.video.title;///this  
is the one using the xmlList,
it works but only the last title and with tags there is a way that  
my different video titles will be in the opened windows?

also when I try using the repeater like:
myVimeoWindow.title=vimeo.currentItem.title
is always giving me and error.

}

///here is my repeater, it works, but I cannot open the window as I  
want.
mx:HTTPService id=vimeoService url=http://vimeo.com/api/v2/iglesiafls/videos.xml 
 resultFormat=e4x fault=onFault(event)/
mx:XMLListCollection id=myVimeoList  
source={vimeoService.lastResult.video}/

mx:VBox width=340 height=334 x=699 y=422
mx:Repeater id=vimeo dataProvider={myVimeoList}
		mx:Image source={vimeo.currentItem.thumbnail_medium}  
width=200 height=150/
		mx:Text text={vimeo.currentItem.title} color=#F5FBFC  
fontSize=14 width=300/
		mx:Text text={vimeo.currentItem.description} color=#F5FAFB  
width=300/
		mx:LinkButton label=ver video click=openWindowVimeo(event)  
id=vimeoButton enabled=true/


/mx:Repeater
/mx:VBox

Could someone help me out

gus








RE: [flexcoders] help with a repeater

2011-10-07 Thread Gordon Smith
This poorly-worded message is trying to explain that you cannot access the 
'currentItem' of a Repeater, as your code vimeo.currentItem.title in 
openWindowVimeo() is doing, after the Repeater has already created all the 
repeated components. As each repeated component is created, 'currentItem' is 
the item in the dataProvider that is creating that particular component. So 
what would the 'currentItem' of the Repeater be after all the components have 
been created? It doesn't make sense, and therefore is an error.

Once a repeated component has been created, you can use its getRepeaterItem() 
method to get the item in the dataProvider that created it.

Gordon Smith
Adobe Flex SDK Team

From: flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.com] On Behalf 
Of Gustavo Duenas
Sent: Friday, October 07, 2011 5:28 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] help with a repeater



thanks for your help
here is the error log

Error: Repeater is not executing.
at mx.core::Repeater/get 
currentItem()[C:\autobuild\3.3.0\frameworks\projects\framework\src\mx\core\Repeater.as:305]
at iglesiaFls/openWindowVimeo()[/Users/gustavoduenas/Documents/Flex 
Builder 3/iglesiaFls/src/iglesiaFls.mxml:17]
at 
iglesiaFls/__vimeoButton_click()[/Users/gustavoduenas/Documents/Flex Builder 
3/iglesiaFls/src/iglesiaFls.mxml:51]

On Oct 7, 2011, at 12:47 AM, Tandon, Rishi wrote:




You missed the most important thing in message, the error log.
Send over that.


From: Gustavo Duenas 
gdue...@leftandrightsolutions.commailto:gdue...@leftandrightsolutions.com
To: flexcoders@yahoogroups.commailto:flexcoders@yahoogroups.com
Sent: Friday, October 7, 2011 9:47 AM
Subject: [flexcoders] help with a repeater

I have a repeater which! reads a xmllist from vimeo, it works and do the repeat 
but when I tried to pass info from the repeater to the title window, something 
happens and I have an as3
errror. this is  my code.

mx:Script
![CDATA[
import mx.managers.PopUpManager;
import mx.containers.*;
import mx.controls.Alert;
import mx.rpc.events.FaultEvent;
import mx.rpc.events.ResultEvent;
import flsWindow;

private function 
openWindowVimeo(event:MouseEvent):void{
var myVimeoWindow:TitleWindow= 
TitleWindow(PopUpManager.createPopUp(this, flsWindow, true));
!
myVimeoWindow.title=vimeoService.lastResult.video.title;///this is the one 
using the xmlList,
it works but only the last title and with tags there is a way that my different 
video titles will be in the opened windows?
also when I try using the repeater like:
myVimeoWindow.title=vimeo.currentItem.title
is always giving me and error.

}

///here is my repeater, it works, but I cannot open the window as I want.
mx:HTTPService id=vimeoService 
url=http://vimeo.com/api/v2/iglesiafls/videos.xml; resultFormat=e4x 
fault=onFault(event)/
mx:XMLListCollection id=myVimeoList 
source={vimeoService.lastResult.video}/
mx:VBox width=340 height=33! 4 x=699 y=422
mx:Repeater id=vimeo dataProvider={myVimeoList}
mx:Image source={vimeo.currentItem.thumbnail_medium} 
width=200 height=150/
mx:Text text={vimeo.currentItem.title} 
color=#F5FBFC fontSize=14 width=300/
mx:Text text={vimeo.currentItem.description} 
color=#F5FAFB width=300/
mx:LinkButton label=ver video 
click=openWindowVimeo(event) id=vimeoButton enabled=true/

/mx:Repeater
   /mx:VBox

Could someone help me out

gus






Re: [flexcoders] help with a repeater

2011-10-07 Thread Gustavo Duenas
Thank you my friend, you are really good. I guess I should have read  
more the book. It totally works.


Gustavo

On Oct 7, 2011, at 12:21 PM, Gordon Smith wrote:



This poorly-worded message is trying to explain that you cannot  
access the ‘currentItem’ of a Repeater, as your code  
vimeo.currentItem.title in openWindowVimeo() is doing, after the  
Repeater has already created all the repeated components. As each  
repeated component is created, ‘currentItem’ is the item in the  
dataProvider that is creating that particular component. So what  
would the ‘currentItem’ of the Repeater be after all the components  
have been created? It doesn’t make sense, and therefore is an error.




Once a repeated component has been created, you can use its  
getRepeaterItem() method to get the item in the dataProvider that  
created it.




Gordon Smith

Adobe Flex SDK Team



From: flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.com]  
On Behalf Of Gustavo Duenas

Sent: Friday, October 07, 2011 5:28 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] help with a repeater





thanks for your help

here is the error log



Error: Repeater is not executing.

at mx.core::Repeater/get currentItem()[C:\autobuild 
\3.3.0\frameworks\projects\framework\src\mx\core\Repeater.as:305]


at iglesiaFls/openWindowVimeo()[/Users/gustavoduenas/ 
Documents/Flex Builder 3/iglesiaFls/src/iglesiaFls.mxml:17]


at iglesiaFls/__vimeoButton_click()[/Users/gustavoduenas/ 
Documents/Flex Builder 3/iglesiaFls/src/iglesiaFls.mxml:51]




On Oct 7, 2011, at 12:47 AM, Tandon, Rishi wrote:








You missed the most important thing in message, the error log.

Send over that.



From: Gustavo Duenas gdue...@leftandrightsolutions.com
To: flexcoders@yahoogroups.com
Sent: Friday, October 7, 2011 9:47 AM
Subject: [flexcoders] help with a repeater



I have a repeater which! reads a xmllist from vimeo, it works and do  
the repeat but when I tried to pass info from the repeater to the  
title window, something happens and I have an as3


errror. this is  my code.



mx:Script

![CDATA[

import mx.managers.PopUpManager;

import mx.containers.*;

import mx.controls.Alert;

import mx.rpc.events.FaultEvent;

import mx.rpc.events.ResultEvent;

import flsWindow;



private function  
openWindowVimeo(event:MouseEvent):void{


var  
myVimeoWindow:TitleWindow=  
TitleWindow(PopUpManager.createPopUp(this, flsWindow, true));


!

myVimeoWindow.title=vimeoService.lastResult.video.title;///this is  
the one using the xmlList,


it works but only the last title and with tags there is a way that  
my different video titles will be in the opened windows?


also when I try using the repeater like:

myVimeoWindow.title=vimeo.currentItem.title

is always giving me and error.



}



///here is my repeater, it works, but I cannot open the window as I  
want.


mx:HTTPService id=vimeoService url=http://vimeo.com/api/v2/iglesiafls/videos.xml 
 resultFormat=e4x fault=onFault(event)/


mx:XMLListCollection id=myVimeoList  
source={vimeoService.lastResult.video}/


mx:VBox width=340 height=33! 4 x=699 y=422

mx:Repeater id=vimeo  
dataProvider={myVimeoList}


mx:Image  
source={vimeo.currentItem.thumbnail_medium} width=200  
height=150/


mx:Text text={vimeo.currentItem.title}  
color=#F5FBFC fontSize=14 width=300/


mx:Text  
text={vimeo.currentItem.description} color=#F5FAFB width=300/


mx:LinkButton label=ver video  
click=openWindowVimeo(event) id=vimeoButton enabled=true/




/mx:Repeater

   /mx:VBox



Could someone help me out



gus














RE: [flexcoders] help with a repeater

2011-10-07 Thread Gordon Smith
BTW, you should consider moving to Spark components and using a Spark DataGroup 
rather than a Repeater. A DataGroup is more efficient when you have many data 
items that need to be rendered because it only creates item renderers for the 
data items that are visible. Repeater always creates all of them.

Gordon Smith
Adobe Flex SDK Team

From: flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.com] On Behalf 
Of Gustavo Duenas
Sent: Friday, October 07, 2011 9:51 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] help with a repeater



Thank you my friend, you are really good. I guess I should have read more the 
book. It totally works.

Gustavo

On Oct 7, 2011, at 12:21 PM, Gordon Smith wrote:




This poorly-worded message is trying to explain that you cannot access the 
'currentItem' of a Repeater, as your code vimeo.currentItem.title in 
openWindowVimeo() is doing, after the Repeater has already created all the 
repeated components. As each repeated component is created, 'currentItem' is 
the item in the dataProvider that is creating that particular component. So 
what would the 'currentItem' of the Repeater be after all the components have 
been created? It doesn't make sense, and therefore is an error.

Once a repeated component has been created, you can use its getRepeaterItem() 
method to get the item in the dataProvider that created it.

Gordon Smith
Adobe Flex SDK Team

From: flexcoders@yahoogroups.com [mailto:flexcoders@yahoogroups.com] On Behalf 
Of Gustavo Duenas
Sent: Friday, October 07, 2011 5:28 AM
To: flexcoders@yahoogroups.commailto:flexcoders@yahoogroups.com
Subject: Re: [flexcoders] help with a repeater



thanks for your help
here is the error log

Error: Repeater is not executing.
at mx.core::Repeater/get 
currentItem()[C:\autobuild\3.3.0\frameworks\projects\framework\src\mx\core\Repeater.as:305]
at iglesiaFls/openWindowVimeo()[/Users/gustavoduenas/Documents/Flex 
Builder 3/iglesiaFls/src/iglesiaFls.mxml:17]
at 
iglesiaFls/__vimeoButton_click()[/Users/gustavoduenas/Documents/Flex Builder 
3/iglesiaFls/src/iglesiaFls.mxml:51]

On Oct 7, 2011, at 12:47 AM, Tandon, Rishi wrote:





You missed the most important thing in message, the error log.
Send over that.


From: Gustavo Duenas 
gdue...@leftandrightsolutions.commailto:gdue...@leftandrightsolutions.com
To: flexcoders@yahoogroups.commailto:flexcoders@yahoogroups.com
Sent: Friday, October 7, 2011 9:47 AM
Subject: [flexcoders] help with a repeater

I have a repeater which! reads a xmllist from vimeo, it works and do the repeat 
but when I tried to pass info from the repeater to the title window, something 
happens and I have an as3
errror. this is  my code.

mx:Script
![CDATA[
import mx.managers.PopUpManager;
import mx.containers.*;
import mx.controls.Alert;
import mx.rpc.events.FaultEvent;
import mx.rpc.events.ResultEvent;
import flsWindow;

private function 
openWindowVimeo(event:MouseEvent):void{
var myVimeoWindow:TitleWindow= 
TitleWindow(PopUpManager.createPopUp(this, flsWindow, true));
!
myVimeoWindow.title=vimeoService.lastResult.video.title;///this is the one 
using the xmlList,
it works but only the last title and with tags there is a way that my different 
video titles will be in the opened windows?
also when I try using the repeater like:
myVimeoWindow.title=vimeo.currentItem.title
is always giving me and error.

}

///here is my repeater, it works, but I cannot open the window as I want.
mx:HTTPService id=vimeoService 
url=http://vimeo.com/api/v2/iglesiafls/videos.xml; resultFormat=e4x 
fault=onFault(event)/
mx:XMLListCollection id=myVimeoList 
source={vimeoService.lastResult.video}/
mx:VBox width=340 height=33! 4 x=699 y=422
mx:Repeater id=vimeo dataProvider={myVimeoList}
mx:Image source={vimeo.currentItem.thumbnail_medium} 
width=200 height=150/
mx:Text text={vimeo.currentItem.title} 
color=#F5FBFC fontSize=14 width=300/
mx:Text text={vimeo.currentItem.description} 
color=#F5FAFB width=300/
mx:LinkButton label=ver video 
click=openWindowVimeo(event) id=vimeoButton enabled=true/

/mx:Repeater
   /mx:VBox

Could someone help me out

gus








Re: [flexcoders] help with a repeater

2011-10-06 Thread Tandon, Rishi
You missed the most important thing in message, the error log.
Send over that.



From: Gustavo Duenas gdue...@leftandrightsolutions.com
To: flexcoders@yahoogroups.com
Sent: Friday, October 7, 2011 9:47 AM
Subject: [flexcoders] help with a repeater


  
I have a repeater which reads a xmllist from vimeo, it works and do the repeat 
but when I tried to pass info from the repeater to the title window, something 
happens and I have an as3
errror. this is  my code.

mx:Script
![CDATA[
import mx.managers.PopUpManager;
import mx.containers.*;
import mx.controls.Alert;
import mx.rpc.events.FaultEvent;
import mx.rpc.events.ResultEvent;
import flsWindow;

private function openWindowVimeo(event:MouseEvent):void{
var myVimeoWindow:TitleWindow= TitleWindow(PopUpManager.createPopUp(this, 
flsWindow, true));
myVimeoWindow.title=vimeoService.lastResult.video.title;///this is the one 
using the xmlList,
it works but only the last title and with tags there is a way that my different 
video titles will be in the opened windows?
also when I try using the repeater like:
myVimeoWindow.title=vimeo.currentItem.title
is always giving me and error.

}

///here is my repeater, it works, but I cannot open the window as I want.
mx:HTTPServiceid=vimeoService 
url=http://vimeo.com/api/v2/iglesiafls/videos.xml; resultFormat=e4x 
fault=onFault(event)/
mx:XMLListCollection id=myVimeoList 
source={vimeoService.lastResult.video}/
mx:VBox width=340 height=334 x=699 y=422
mx:Repeater id=vimeo dataProvider={myVimeoList}
mx:Image source={vimeo.currentItem.thumbnail_medium} width=200 
height=150/
mx:Text text={vimeo.currentItem.title} color=#F5FBFC fontSize=14 
width=300/
mx:Text text={vimeo.currentItem.description} color=#F5FAFB width=300/
mx:LinkButton label=ver video click=openWindowVimeo(event) 
id=vimeoButton enabled=true/

/mx:Repeater
/mx:VBox

Could someone help me out

gus
 

RE: [flexcoders] help with databinding -- repeater listening for event?

2008-04-03 Thread Tracy Spratt
I may not be understanding correctly, but if you re-assign the
Repeater.dataProvider, the repeater should re-execute.   You should not
have to do anything else.  

 

Are you re-assigning the dataProvider?  Or are you counting on the
binding updating the dataProvider?   If the second, verify that the
singleton binding is working correctly.  Maybe create a test
ChangeWatcher?  Binding can be hard to debug.

 

Tracy 

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of grimmwerks
Sent: Thursday, April 03, 2008 4:21 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] help with databinding -- repeater listening for
event?

 

I'm a bit frustrated here and hope someone can point out where I've gone
wrong.

 

I've got a repeater that is drawing out 4 circles and binding to a
Singleton class' variable via binding -- all this works well the first
time -- the Singleton class is loading in xml that holds the x/y and
size coords for these 4 circles.

 

I want to load in the next 4 circles xml and have the repeater redraw
these 4 circles - how best to do this? If I'm using a custom canvas to
draw these 4 circles; should the canvas itself redraw upon the
CircleData.getInstance().currentCircle change?!?

 

 

If it's not clear what I'm doing, here's some code.

 

main.mxml is drawing out a CircleLayout.mxml as a component (Canvas),
and inside there is:

 

 

mx:Repeater id=rep
dataProvider={CircleData.getInstance().currentCircle.circle}

mx:Button   x={Number([EMAIL PROTECTED])}
y={Number([EMAIL PROTECTED])}
width={(Number([EMAIL PROTECTED])*defaultSize)} 


height={(Number([EMAIL PROTECTED])*defaultSize)}
styleName={String([EMAIL PROTECTED])}
label={String([EMAIL PROTECTED]).toUpperCase()} 


useHandCursor={CircleData.getInstance().isEdit}
buttonMode={CircleData.getInstance().isEdit}/

/mx:Repeater 

   

   

 

And within the CircleData class:

 

public function setCircleData(event:Event):void{

circlesList = new XML(xmlURLLoader.data);

pos = circlesList.item.length()-1;

var tmp:XMLList = [EMAIL PROTECTED];

// change this datelist constructor to have id# of
cirlce items

dateList = new ArrayCollection();

for(var i:uint=0; itmp.length(); i++){

dateList.addItem({label: tmp[i],
data:i});

}

loadCircles(pos);

}

public function loadCircles(newPos:Number):void{

currentCircle = circlesList.item[pos];

}

 

And the combo box is really just doing
CircleData.getInstance().loadCircles(pos)

 

But the repeaters aren't firing off the redraw again?