Back long ago with a ultrawebgrid we use to call
var grid = igtbl_getGridById(gsGridName);
grid.Rows.refresh();
this would make everything work great.
After reading a few posts here, it looks like the recommended way of refreshing a grid from javascript is to use an ajax updatepanel with a button in it. For test purposes I just click the button. Great, the grid is refreshed. The problem is that I do not see the ajax refresh image while it reloads.
Am I doing this correctly?
Hello mland ,
Since the grid won’t be the one invoking the update its ajax indicator won’t show. You can however manipulate when it shows and hides manually.
Here are the steps you need to take:
1.Handle the button's onClientClick event and in it get the instance of the ajax indicator and show it with:
wdg.get_ajaxIndicator().show(wdg);
2. Use Sys.WebForms.PageRequestManager to hook a method to handle events after the asynchronous postback has finished.( For more information on this refer to: http://msdn.microsoft.com/en-us/library/bb311028.aspx .)For example:
var prm = Sys.WebForms.PageRequestManager.getInstance();
prm.add_endRequest(pageReloaded);
And in that method hide the ajax indicator:
function pageReloaded() {
var wdg1 = $find("WebDataGrid1");
wdg1.get_ajaxIndicator().hide();
}
Let me know if you have any questions or concerns regarding this.
Best Regards,
Maya Kirova
Developer Support Engineer
Infragistics, Inc.
http://ko.infragistics.com/support
Since the grid won’t be the one invoking the update its ajax indicator won’t show.
Is there a way to get the grid to invoke the update? I like the ultragrid way of updating, is there something similar I can do with WHDG?