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

How to show wait cursor over grid

3 Answers 548 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Richard
Top achievements
Rank 1
Richard asked on 09 Jun 2014, 11:59 PM
I have a 3 level hierarchical Kendo grid with command columns that invoke long-running JavaScript Ajax functions that invoke Controller methods which in turn act on database tables.  I'm trying to show a wait cursor so the user has a visual cue that the system is busy and is waiting for a response from the server.  Kendo grid CSS seems to be overriding my attempt to show and clear the wait cursor.  How can I make this work properly?

My Javascript method is shown below:

function onClickPostBatch(e) {
    var dataItem = this.dataItem($(e.target).closest("tr"));
    //document.body.style.cursor = "wait";
    $("html").css("cursor", "wait");
      $.post('@Url.Action("PostBatch", "Home")', {
         batchId: dataItem.BatchID
     }, function (data) {
         if (data.error) {
            alert('' + data.message);
        } else {
            alert(data.message);
            location.reload();
        }
     });
    //document.body.style.cursor = "default";
    $("html").css("cursor", "default");
 }


Thanks!

Rich

3 Answers, 1 is accepted

Sort by
0
Kiril Nikolov
Telerik team
answered on 10 Jun 2014, 11:25 AM
Hi Richard,

You can use the built-in Kendo UI Progress indicator for your grid. Please check the following example and let me know if it helps:

http://trykendoui.telerik.com/@Kiril/ozuv

Regards,
Kiril Nikolov
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Richard
Top achievements
Rank 1
answered on 10 Jun 2014, 10:53 PM
Thanks!  That did the trick!
0
Kiril Nikolov
Telerik team
answered on 11 Jun 2014, 07:38 AM
Hello Richard,

I am glad that the proposed solution helped.

In case you have any further questions, please do not hesitate to contact us.

Regards,
Kiril Nikolov
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Grid
Asked by
Richard
Top achievements
Rank 1
Answers by
Kiril Nikolov
Telerik team
Richard
Top achievements
Rank 1
Share this question
or