This is a migrated thread and some comments may be shown as answers.

Reload KendoUI after AJAX Request?

3 Answers 199 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Matthew
Top achievements
Rank 1
Matthew asked on 04 Oct 2012, 02:59 PM
We are using KendoUI to build some of our widgets, along with using ASP and Razor. We are getting some of these widgets delivered through a click, which fills in a div (using AJAX) with the appropriate HTML. The problem, is that the KendoUI is already loaded, and so the HTML delivered via AJAX is not styled, nor made into widgets from KendoUI. 

Is there a way to "reload" the KenoUI JavaScript with each AJAX request?

3 Answers, 1 is accepted

Sort by
0
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
answered on 05 Oct 2012, 08:04 PM
Would it be possible to instead of delivering html to use JSON and have kendo just render it out with templates?...it'd defiantly be faster
0
Asif Hossain
Top achievements
Rank 1
answered on 07 Jan 2013, 02:47 PM
Hi Support Team,
In kendo UI Grid, i have list of model object with paging enabled, when i perform an operation (e.g. Delete row 25 in page 5) via ajax json call, then i have removed one item from the model object and now in the view,  i want to see the 25th number row is removed and be in the same page 5 of the grid.
What can be done after each successful Ajax call to the view ?
 $.ajax({
            url: "/Home/CloseMail/",
            data: {
                emailID: mailID
            },
            cache: false,
            type: "POST",
            timeout: 10000,
            dataType: "json",
            success: function (result) {
                if (result.Success) { 
                  /////////////// WHAT HERE ??????
                } else {
                    alert("Operation Failed");
                }
            }
        });


Simply reload the page is not desired. Because in this case we will lost the page 5 in the Grid.

Regards,
0
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
answered on 07 Jan 2013, 03:08 PM
Kind of depends on how it's setup...

http://demos.kendoui.com/web/grid/editing-inline.html
Tags
General Discussions
Asked by
Matthew
Top achievements
Rank 1
Answers by
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
Asif Hossain
Top achievements
Rank 1
Share this question
or