1 Reply Latest reply on Feb 24, 2009 8:35 AM by Newsgroup_User

    Datagrid with checkbox in its column


      In my application I have a datagrid (a custom datagrid - CheckBoxDatagrid), whose first colum contains checkbox as itemrenderer. There is another column (Latest Version) - this column can have two values either "Available" or "Update".

      The requirement here is that, when the page is getting loaded then depending on the value of the column "Latest Version" the checkboxes will have to be loaded. If the value of the coluem is "Available", then the checkbox corresponding to that row should get automatically selected as soon as the page gets loaded.

      I am attaching the code snippet below,

      <configure:CheckBoxDataGrid id="swDataGrid" initialize="swDataGrid.dataProvider=MaintenanceViewController.softwareList" alternatingItemColors="[#ffffff, #ffffff]" paddingLeft="10" paddingRight="5"
      allowMultipleSelection="true" width="95%" height="60%" paddingBottom="5" selectionColor="#1b77b7" verticalGridLines="false" creationComplete="{MaintenanceViewController.checkBoxSelect()};">
      <configure:columns>
      <mx:DataGridColumn id="checkBox" dataField="softwarename" textAlign="center" headerText=" " width="20" sortable="false" itemRenderer="com.pmc.view.tasks.wizard.CheckBoxRenderer" editable="false">
      </mx:DataGridColumn>
      <mx:DataGridColumn id="swName" headerText="Software Name" dataField="softwarename" width="130"/>
      <mx:DataGridColumn id="cVersion" headerText="Current Version" dataField="currentversion" width="80"/>
      <mx:DataGridColumn id="updStatus" headerText="Update Status" dataField="updateStatus" width="80"/>
      </configure:columns>
      </configure:CheckBoxDataGrid>

      where, configure = defined namespace.
        • 1. Re: Datagrid with checkbox in its column
          Level 7

          "BlueRHBA" <webforumsuser@macromedia.com> wrote in message
          news:go0hkf$2kt$1@forums.macromedia.com...
          > In my application I have a datagrid (a custom datagrid -
          > CheckBoxDatagrid),
          > whose first colum contains checkbox as itemrenderer. There is another
          > column
          > (Latest Version) - this column can have two values either "Available" or
          > "Update".
          >
          > The requirement here is that, when the page is getting loaded then
          > depending
          > on the value of the column "Latest Version" the checkboxes will have to be
          > loaded. If the value of the coluem is "Available", then the checkbox
          > corresponding to that row should get automatically selected as soon as the
          > page
          > gets loaded.
          >
          > I am attaching the code snippet below,

          What is your question? Or are you looking to hire someone to fulfill your
          requirement?