Pages

Monday, December 21, 2009

Hooking into the CRM Grid Refresh

For those of us who heavily extend CRM with javascript, there is an event handler I've just found and used for a project that I'm working on that allows you to hook into the refresh of a crmGrid object.  This is an example of how to use the event:

function GridRefresh () {
  alert("The grid has refreshed.");
}

document.all.crmGrid.attachEvent("onrefresh", GridRefresh);

UPDATE: I discovered recently that this event will not be triggered in the event of a view change.  As near as I can tell, there is no event that is triggered when the view is changed.

2 comments:

  1. In the CRM Grid HTC file (I forget which one) you can raise this event. It's a fairly innocuous mod that is well worth it if you intend to perform custom actions on the grids.

    ReplyDelete
  2. Thanks a lot, David. You helped me a lot!

    ReplyDelete

Unrelated comments to posts may be summarily disposed at the author's discretion.