Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by LeitrimMan on Dec 04, 2009 07:22
open dhtmlx forum
User feedback when grid/tree loading

Hi,

I am trying to provide user feedback when loading data into both trees and grids on my application, i am using the event onXLS and onXLE but not haing much success.. i.e.

grid

                crewPrevGrid.attachEvent("onXLS",function(grid_obj){document.body.style.cursor='wait';});
                crewPrevGrid.attachEvent("onXLE",function(grid_obj){document.body.style.cursor='default';});

tree

            CrewTree.attachEvent("onXLS",function(tree,id){document.body.style.cursor='wait';});
                CrewTree.attachEvent("onXLE",function(tree,id){document.body.style.cursor='default';});

The tree one seems to work ok (I think) but the grid one doesn't it fires the event ok (I want to change default cursor, when loading or filtering on the grid). What is the correct syntax for this, am I doning something wrong??

thanks!
Answer posted by Alex (support) on Dec 04, 2009 08:12

Hello,

onXLS and onXLE are called correctly for both components. Please, provide the sample where these events fail.]

Regarding filtering in grid  - you can try to use onFilterStart and onFilterEnd event.

Answer posted by LeitrimMan on Dec 05, 2009 04:42

Hi Alex,

its seems to be irregular behaviour. I added onFilterStart and onFilterEnd too with alerts in the functions as per

 

    crewPrevGrid.attachEvent("onXLS",function(grid_obj){alert("onXLS");document.body.style.cursor='wait';});
    crewPrevGrid.attachEvent("onXLE",function(grid_obj){alert("onXLE");document.body.style.cursor='default';});  
    crewPrevGrid.attachEvent("onFilterStart",function(grid_obj){alert("onFilterStart");document.body.style.cursor='wait';});
    crewPrevGrid.attachEvent("onFilterEnd",function(grid_obj){alert("onFilterEnd");document.body.style.cursor='default';});  

What happens is that onXLS and onXLE seem to fire correctly, but the cursor doesn't change! So it appears the error is not on the event being thrown but in changing the cursor.. In the meantime I'll have a look at a progress bar or gif indicator..

 

Answer posted by Alex (support) on Dec 07, 2009 01:28

Hello,

please provide the complete demo to recreate the issue. If the demo contains PRO libraries, please send it to support@dhtmlx.com