3 Replies Latest reply on Jun 26, 2009 3:37 AM by karthik flex

    about itemrenderer?

    karthik flex Level 1

      hi

       

      i am using one common itemrenderer  i.e IDropInListItemRenderer
      i have different datagrid column that is accessing this itemrenderer is there any option of stop executing the itemrenderer for a particular datagridcolumn

      i.e for some column it should execute and for others it should not

       

      because one itemrenderer for all datagrid column

       

      any idea

       

      karthik.k

        • 1. Re: about itemrenderer?
          vachik79

          Hi, maybe this will help..

           

          <mx:AdvancedDataGrid id="myADG" >  
               <mx:columns>
                   <mx:AdvancedDataGridColumn dataField="id" width="50" sortable="false"/>
                   <mx:AdvancedDataGridColumn dataField="name"  sortable="false"/>
                   <mx:AdvancedDataGridColumn dataField="detail" sortable="false" />
               </mx:columns>  
                  
               <mx:rendererProviders>           
                   <mx:AdvancedDataGridRendererProvider 
                       dataField="detail"
                       renderer="myComponents.renderer"
                      columnIndex="2"                         
                       />           
                 
               </mx:rendererProviders> 

          </mx:AdvancedDataGrid>

           

          this is only applied to 3 column .

          • 2. Re: about itemrenderer?
            karthik flex Level 1

            hi

            my call to renderer will be like below

             

            <mx:AdvancedDataGrid id="myADG" >  
                 <mx:columns>
                     <mx:AdvancedDataGridColumn dataField="id" width="50" sortable="false" itemRenderer="myrenderer"/>
                     <mx:AdvancedDataGridColumn dataField="name"  sortable="false" itemRenderer="myrenderer"/>
                     <mx:AdvancedDataGridColumn dataField="detail" sortable="false" itemRenderer="myrenderer" />
                 </mx:columns>

            </mx:AdvancedDataGrid>

             

            and i need to ececute renderer if id comes it shoild execcute one block and if name comes it should execute another block

            because if one renderer is there for all "id" data is diaplayed in "name" cloumn which is confusing

             

            any idea

             

            karthik.k

            • 3. Re: about itemrenderer?
              karthik flex Level 1

              hi

               

              i have one doubt

               

              <mx:AdvancedDataGrid id="myADG" >  
                   <mx:columns>
                       <mx:AdvancedDataGridColumn dataField="id" width="50" sortable="false" itemRenderer="myrenderer"/>
                       <mx:AdvancedDataGridColumn dataField="name"  sortable="false" itemRenderer="myrenderer"/>
                       <mx:AdvancedDataGridColumn dataField="detail" sortable="false" itemRenderer="myrenderer" />
                   </mx:columns>

              </mx:AdvancedDataGrid>

               

               

              how to find dataField="id" "id" is coming in to myrendereror dataField="name" "name" coming to myrenderer

               

              how to find which data is coimng into renderer

               

              any idea

               

              karthik.k