Salut,

voila je suis coincé, j'ai un TileList qui contient un composant à moi, j'arrive très bien à l'afficher en utilisant le tag <mx:itemRenderer> mais par contre j'ai besoin de faire des actions dessus, comme remplir des datagrids, cacher des labels...

Et j'ai beau passé du temps sur le net à la recherche d'info, je suis perdu

alors voila mon bout de code mxml :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
<mx:TileList id="boxUnmatching" 
		rowHeight="{boxUnmatching.height/2-20}" columnWidth="{boxUnmatching.width-15}" 
		width="100%" height="100%" maxColumns="1"
		selectable="false" backgroundColor="#fafa5a">
	 	<mx:itemRenderer>
               <mx:Component>
                  		<views:Proposition/>
               	</mx:Component>
            </mx:itemRenderer>
	</mx:TileList>
et mon composant :

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<mx:VBox xmlns:mx="http://www.adobe.com/2006/mxml" 
	xmlns:views="com.axway.osredi.flex.views.*"
	xmlns:controllers="com.axway.osredi.flex.controllers.*" 
	backgroundColor="#ffd5ff" width="100%" height="100%"
	creationComplete="{propositionController.initialize(this)}"
	borderStyle="inset"> 
 
	<controllers:PropositionController id="propositionController"/>	
 
	<mx:VBox id="contenant" height="100%" width="100%">
		<mx:HBox id="hb_1" width="100%" height="5%">
			<mx:CheckBox id="checkbox" width="30" height="100%"/>
			<mx:Label text="Proposition :" height="100%" fontWeight="bold" fontSize="11" width="91" paddingTop="13"/>
			<mx:Spacer height="100%" width="70%"/>
			<mx:VBox id="detailMatching" width="25%" height="100%" visible="false">				
				<mx:HBox id="detailLettrageOK" width="100%" height="50%">
					<mx:Label text="Lettré par : " fontWeight="bold"/>	
					<mx:Label id="userLettrage" fontWeight="bold"/>	
					<mx:Label text=" Le : " fontWeight="bold"/>	
					<mx:Label id="dateLettrage" fontWeight="bold"/>	
				</mx:HBox>
				<mx:HBox id="detailDelettrageOK" width="100%" height="50%" visible="false">
					<mx:Label text="Delettré par : " fontWeight="bold"/>	
					<mx:Label id="userDelettrage" fontWeight="bold"/>	
					<mx:Label text=" Le : " fontWeight="bold"/>	
					<mx:Label id="dateDelettrage" fontWeight="bold"/>	
				</mx:HBox>
			</mx:VBox>
		</mx:HBox>
		<mx:HDividedBox height="90%" width="100%">
			<mx:Panel id="panelFacture" width="50%" height="100%" title="Factures" textAlign="left">
				<mx:DataGrid id="dgFacture" width="100%" height="100%"  allowMultipleSelection="true" horizontalScrollPolicy="auto" dragMoveEnabled="true" dragEnabled="true" dropEnabled="false">
					<mx:columns>
						<mx:DataGridColumn/>
					</mx:columns>
				</mx:DataGrid>
			</mx:Panel>
			<mx:Panel id="panelRebut" width="50%" height="100%" title="Rebut" textAlign="left">
				<mx:DataGrid id="dgRebut" width="100%" height="100%"  allowMultipleSelection="true" horizontalScrollPolicy="auto" dragMoveEnabled="true" dragEnabled="true" dropEnabled="false">
					<mx:columns>
						<mx:DataGridColumn/>
					</mx:columns>
				</mx:DataGrid>
			</mx:Panel>
		</mx:HDividedBox>
		<mx:HBox width="100%" height="5%">
			<mx:Button id="duplicateLine" label="Dupliquer une ligne" enabled="true"/>
			<mx:Button id="deleteLine" label="Supprimer une ligne" enabled="true"/>
		</mx:HBox>
	</mx:VBox>
</mx:VBox>
En fait sur un evenement j'affiche ma tilelist, et je veux rempli les datagrid de mon composant

voila la function que je fait pour afficher mon tilelist :

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
		public function getMatchingsResult(matchingList:ArrayCollection):void{
 
			for each (var matching:Matching in matchingList){
				var newProp:Proposition= new Proposition();
				propArray.addItem(newProp as Proposition); 
 
				//displayMatching(matching);
			}
			delettrage.boxUnmatching.dataProvider=propArray as ArrayCollection;
Et en fait je souhaiterai juste faire un truc du style newProp.checkbox.visible=false
Mais je ne peux pas j'ai un nul pointer exception

Alors si qq un pouvait me donner une piste parce que la je craque

Merci beaucoup