I have installed the Grid.MVC http://gridmvc.codeplex.com/ inside my asp.net mvc5 web application. but now when i click on the filter icon beside a column i will get the following exception:-

> Unhandled exception at line 1, column 2416 in
> http://localhost:55951/Scripts/gridmvc.min.js
> 
> 0x800a01b6 - JavaScript runtime error: Object doesn't support property
> or method 'hasAttribute'

here is the code that will raise the exception inside the gridmvc.min.js file:-

function(t,i){var o=n(this).attr("data-type")||"",r=t.getFilterWidgetForType(o),u,h,e,c;if(r==null)return!1;if(this.hasAttribute("data-rendered"))return u=t.openMenuOnClick.call(this,t

so can anyone adivce on this please?

EDIT

i commented the code which is causing the error inside the script file,

 //if (this.hasAttribute("data-rendered")) {
      //  var or = self.openMenuOnClick.call(this, self);
      //   self.setupPopupInitialPosition($(this));
      //    if (!or && typeof (widget.onShow) != 'undefined')
      //        widget.onShow();
      //  return or;
      //  }

And now the filter box will be shown, but if i select any thing inside the type drop down the same filter box will be shown as follow:-

enter image description here

Thanks

1

There are 1 best solutions below

2
On

This issue in only in IE browser. Please check IE browser compatibility mode it should be "Edge". Also add 'meta http-equiv="X-UA-Compatible" content="IE=edge"' in head tag.