Kendo Grid - Hide newly added row while editing in Popup

3 posts, 0 answers
  1. Anthar
    Anthar avatar
    2 posts
    Member since:
    Jun 2016

    Posted 01 Nov Link to this post

    I am using Kendo grid with editable popup and I want to hide/not use the row which is showing editing changes on runtime. 

    Reason:  

    I have a kendo multiselect control in popup and on saving data it adds multiple rows in db and it should show in grid as well. That's why I don't want to show that editing changes line. 

     

  2. Anthar
    Anthar avatar
    2 posts
    Member since:
    Jun 2016

    Posted 03 Nov Link to this post

    Solution
    I was looking for a property of Kendo Grid to not show the editing row but didn't found so I removed the first row in edit function of Kendo Grid

     

    $("#MyKendoGrid").kendoGrid({
        dataSource: myDataSource,
        //
        // other properties
        //
        edit: function (e) {
            $("#MyKendoGrid .k-grid-content table tr:first").remove();
        }
    });
  3. Kendo UI is VS 2017 Ready
  4. Stefan
    Admin
    Stefan avatar
    264 posts

    Posted 04 Nov Link to this post

    Hello Anthar,

    After inspecting the provided solution, I can suggest instead of removing the row to hide it, as removing it can create different issues later on with some of the Grid' features:

    edit: function (e) {
     $("#grid .k-grid-content table tr:first").hide();
    }

    I hope this is helpful.

    Regards,
    Stefan
    Telerik by Progress
     
    Build rich, delightful, *native* Angular 2 apps with Kendo UI for Angular 2. Try it out today! Kendo UI for Angular 2 (currently in beta) is a jQuery-free toolset, written in TypeScript, designed from the ground up to offer true, native Angular 2 components.
     
Back to Top