Update Multiple Rows on cellClose event

2 posts, 0 answers
  1. Derian
    Derian avatar
    4 posts
    Member since:
    Aug 2020

    Posted 17 Aug 2020 Link to this post

    I'm using the cellClose event to update cell values, it works within the values in the selected row. I have a last row called Total which is the sum of the Values of the Column D
    ----------Column_A Column_B Column_C Column_D
    Column D= Column_C * Column_B and ValueT = ValueD1 + ValueD2
    When i update ValueC1 or ValueB1 , ValueD1 gets updated and re-rendered with the new value . The problem is that the ValueT gets udpated but it doesnt re-render .
    The code i have is this one :

    cellClose:function(e){<br>    var dataItem=e.sender.dataItem($(e.container).parent())// getting the current edited row<br>    var aux= e.sender.dataSource.data(); //getting all rows<br>    var dataTotal= aux[aux.length-1]; //geting total row<br>    <br>    valueB=dataItem["Column_B"];<br>    valueC=dataItem["Column_C"];<br>    dataItem.set("Column_D",valueB*ValueC);<br>    <br>      var sum=0;<br>       for (let i=0;i<aux.length-1;i++)//getting sum of values of Column_D<br>       {<br>               sum=sum+aux[i].Column_D;<br>       } <br>      dataTotal.set("Column_D",sum) // setting sum<br>    <br>    <br>    } <br>


  2. Petar
    Petar avatar
    472 posts

    Posted 19 Aug 2020 Link to this post

    Hi Derian,

    This post is a duplicate of a support thread that you've already submitted. To keep the communication consistent, I would like to ask you to continue the discussion in the support ticket #480962. 

    Progress Telerik

Back to Top