how to get only last selected row from checkbox selection model multi selection

  1. #1

    how to get only last selected row from checkbox selection model multi selection

    Hi

    i have gridpanel with CheckboxSelectionModel multiple select i want to get only the last selected row on event rowselect, so evry time i click in row it will be updated in my data base

    i tryed
    <ext:Parameter Name="FrId" Mode="Raw" Value="Ext.encode(#{GridPanel1}.getRowsValues({selectedOnly : true}))" Encode="true" />
    it get all recordId

    and when i tried this
      <ext:Parameter Name="ProduitId" Value="this.getSelected().id" Mode="Raw" />
     <ext:CheckboxSelectionModel ID="CheckboxSelectionModel1" runat="server" MoveEditorOnEnter="false">
        <DirectEvents>
           <RowSelect OnEvent="Update_Selection_Activate">
               <ExtraParams>
                    <ext:Parameter Name="FrId" Mode="Raw" Value="Ext.encode(#{GridPanel1}.getRowsValues({selectedOnly : true}))" Encode="true" />
               </ExtraParams>
           </RowSelect>
           <RowDeselect OnEvent="Update_Selection_Desactivate">
           </RowDeselect>
         </DirectEvents>
    </ext:CheckboxSelectionModel>
    it get only the first selected row so how can i get the last selected row???
  2. #2
    Hi,

    Please try
    <RowSelect ...>
        <ExtraParams>
            <ext:Parameter 
                Name="selectedId" 
                Mode="Raw" 
                Value="record.id" />
        </ExtraParams>
    </RowSelect>
  3. #3
    thx Daniil

    its very helpful

Similar Threads

  1. Replies: 1
    Last Post: Mar 11, 2012, 4:03 AM
  2. binding checkbox selection model
    By VipulTyagi in forum 1.x Help
    Replies: 2
    Last Post: Apr 07, 2011, 12:36 PM
  3. [CLOSED] checkbox selection model
    By majestic in forum 1.x Premium Help
    Replies: 3
    Last Post: Nov 24, 2010, 2:22 PM
  4. Replies: 4
    Last Post: Oct 06, 2010, 10:08 AM
  5. Checkbox selection model + getRowsValues
    By Birgit in forum 1.x Help
    Replies: 10
    Last Post: Sep 06, 2010, 6:12 PM

Posting Permissions