Update Total Footer for a column when a cell is modified RadGrid in EditMode="Batch"

8 posts, 0 answers
  1. Raul
    Raul avatar
    5 posts
    Member since:
    Dec 2013

    Posted 12 Dec 2013 Link to this post

    Hello,

    I have a RadGrid  with columns defined at design time (GridBoundColumn, GridNumericColumn), the grid is configured as EditMode="Batch", when the user clicks on a cell, the cell change to be editable,

    I am using the built in feature to display aggreate functions on the grid (Aggregate="Sum"), the problem is that the user modify the value on a cell, but the value on the footer for that column do not be updated,

    My expectation is, that each modification on the column, should be reflected on the total,

    Could you pelase support me with that?

    Thanks in advance,
  2. Angel Petrov
    Admin
    Angel Petrov avatar
    1007 posts

    Posted 17 Dec 2013 Link to this post

    Hello Raul,

    I am sorry to say but in the current implementation of the grid this is not supported. You can however change the value manually by subscribing to the OnBatchEditCellValueChanged event and using JavaScript change the footer's cell value. Please note that if you click on the Save Changes button the value should get updated automatically.

    Regards,
    Angel Petrov
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Ramey
    Ramey avatar
    19 posts
    Member since:
    Feb 2016

    Posted 24 Feb in reply to Angel Petrov Link to this post

    Angel,

    Could you provide an example of this?

    Thanks,

    Ramey

  5. Angel Petrov
    Admin
    Angel Petrov avatar
    1007 posts

    Posted 29 Feb Link to this post

    Hi Ramey,

    Attached you can find a sample web site which illustrates the approach. It is fully runnable just place the Telerik assemblies in the bin folder.

    Regards,
    Angel Petrov
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  6. Ramey
    Ramey avatar
    19 posts
    Member since:
    Feb 2016

    Posted 29 Feb in reply to Angel Petrov Link to this post

    Good morning Angel,

    Thank you for your response, I opened the website and ran it and it ran properly except for when adding a new record it will give you NaN value.

    Ramey

  7. Angel Petrov
    Admin
    Angel Petrov avatar
    1007 posts

    Posted 02 Mar Link to this post

    Hi Ramey,

    Indeed your observation are correct. Attached you can find a modified version of the sample in which this problem is not reproducible.

    Regards,
    Angel Petrov
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  8. roy
    roy avatar
    8 posts
    Member since:
    Mar 2011

    Posted 02 Aug Link to this post

    Hi Angel,

    your solution is working perfectly for me as well - but:

    for some reason it only works if the calculated column is the first column in the grid!

    if i add columns before it i get an error since footerCell.children is empty

     

    any ideas?

  9. roy
    roy avatar
    8 posts
    Member since:
    Mar 2011

    Posted 02 Aug Link to this post

    so... can ignore the last post.... feel a little slow i missed the page loud function

    so nevermind your code works perfectly for me 

Back to Top
UI for ASP.NET Ajax is Ready for VS 2017