flex repeater¿Ø¼þRepeater is not executing"µÄÒì³£
flex repeater¿Ø¼þ×¢Òâ
Repeater ¹ËÃû˼Ò壬Repeat¾ÍÊÇÖظ´µÄÒâ˼£¬ Repeater ¾ÍÊÇÓÃÀ´Öظ´µÄ¿Ø¼þ
Repeater »á¸ù¾ÝÊý¾ÝÔ´ÖжÔÏóµÄ¶àÉÙÀ´²úÉú¶àÉÙ¸ö×ÓÏÉú³ÉµÄ×ÓÏîÈ«²¿ÊÇÒÔÊý×éÐÎʽ´æÔÚµÄ
<mx:Repeater id="myRepeater" dataProvider="{myArray}">
<mx:HBox>
<mx:LinkButton id="myLabel" label="{myRepeater.currentItem.name}" click="show(event.currentTarget.getRepeaterItem())"/>
<mx:TextInput text="{myRepeater.currentItem.age}"/>
</mx:HBox>
</mx:Repeater>
Óиö³£¼ûµÄÎÊÌ⣺
·¢ÏÖûÓУ¬ÎÒÃÇƽʱµ÷Óú¯Êýʱ´«µÝRepeater ÖеÄ×Ö¶Î×÷Ϊ²ÎÊýʱ£¬ÊDz»¿ÉÒÔ´«µÝµÄ»á³öÏÖ" Repeater is not executing"µÄÒì³£
µ«ÊÇÓÐgetRepeaterItem()Õâ¸ö¶«¶«£¬Êǽâ¾öÕâ¸öÎÊÌâµÄ×îºÃµÄ·½°¸
ÉõÖÁÎÒÃDz»ÐèÒª´«µÝgetRepeaterItem()
´«µÝÒ»¸öevent¹ýÈ¥¾ÍºÃÁË£¬Ê¹ÓÃevent.currentTarget.getRepeaterItem()£¬
ͬÑù¿ÉÒÔ»ñµÃµ±Ç°¶ÔÏóµÄcurrentItem
,»¹ÓÐÒ»¸ö½¨Òé¾ÍÊÇÎÒÃÇƽʱÈç¹ûÄÜÓÃDataGrid½â¾öµÄ£¬¾Í²»ÒªÊ¹ÓÃRepeaterÈ¥´¦Àí£¬RepeaterÔÚЧÂÊ»áÉÏ´ó´òÕÛ¿Û
½¨ÒéѧϰflexµÄÈËÈ¥http://livedocs.adobe.com/flex/3/html/index.html¹Ù·½flexÎĵµÈ¥¿´¿´
ËäȻӢÎIJ»ºÃ£¬µ«ÊÇ´úÂëÎÒÃÇ×ÜÄÜ¿´¶®£¬¶ÔѧϰflexµÄÈË´óÓÐñÔÒæ
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
<mx:Script>
<!--[CDATA[
import mx.messaging.AbstractConsumer;
import mx.collections.ArrayCollection;
private var my:Array=[{name:"a",age:1},{name:"b",age:2},{name:"c",age:3}];
[Bindable]
private var dp:ArrayCollection=new ArrayCollection(my);
]]-->
</mx:Script>
<mx:VBox x="144" y="118" width="319" height="224">
<mx:Repeater id="rp" dataProvider="{dp}">
<mx:RadioButton label="{rp.currentItem.name}" click="aa.text=event.target.getRepeaterItem().age"/>
</mx:Repeater>
<mx:TextInput id="aa"/>
</mx:VBox>
</mx:Application>
Ïà¹ØÎĵµ£º
<?xml version="1.0" encoding="utf-8"?>
<!-- Simple example to demonstrate the DateTimeAxis class. -->
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
<mx:Script>
import mx.collections.ArrayCollection;
......
package
{
import mx.containers.Panel;
import mx.controls.Button;
import flash.events.Event;
import mx.events.FlexEvent;
import flash.events.MouseEvent;
import mx.controls.Alert;
/**
* This class is used to create a Custom Panel
* with Maximum, Minimum, close
* and also drag p ......
Æäʵһ°ãµÄÇé¿öÏÂÊDz»»áÓõ½ÕâÖÖÇé¿öµÄ£¬Ò»°ãÔÚ³ÌÐòÀ±ÈÈçÑ¡ÖÐÒªÌîдµÄÏîÄ¿£¬¶¼Ï²»¶ÓÐÒ»¸öÑ¡ÖеÄ״̬£¬µ«ÊÇÏÖÔÚÎÒÃÇÀ´¸ö·´ÆäµÀ¶øÐÐ,Èç¹ûÎÒ²»ÏëÒªÕâ¸ö״̬¸ÃÔõô°ìÄØ?
²Î¿¼ÁËЩ×ÊÁÏ,ÆäʵҲ¼òµ¥,Óкü¸ÖÖ·½·¨£¬µ«ÊÇ·¢ÏÖÁËÒ»¸ö×îÓÐÓõķ½·¨,Ê×ÏÈÎÒÃÇÔÚÎę̀ÉÏËæÒâ·Å¼¸¸öTEXTINPUT ......
±¾ÏµÁÐÎÄÕÂÖ÷Òª½éÉÜÁ˹ØÓÚFlexÓë.NET½áºÏ¿ª·¢ÖеÄһЩ»¥²Ù×÷ÐÔ£¬°üÀ¨ÍøÂçͨÐÅ¡¢Êý¾Ý¼ÓÔØ¡¢Êý¾Ý´«Êä¡¢Îļþ´«Êä¡¢ÒÔ¼°Ó¦ÓÃÓÚFlexÓë.NETÐ×÷¿ª·¢µÄͨÐÅÍø¹Ø¿ªÔ´ÏîÄ¿FluorineFxµÄÏà¹Ø֪ʶµã¡£
¿ªÔ´ÏîÄ¿FluorineFx¾ÍÊÇרÃÅÕë¶Ô.NETƽ̨ÓëFlexͨÐÅÌṩµÄAMFÐÒéͨÐÅÍø¹Ø£¬ÎÒÃÇ¿ÉÒÔͨ¹ ......