FilterToolbar in IE7

Jun 14, 2011 at 4:56 PM

I'm having trouble using the FilterToolbar in IE7, it works in IE8, firefox and others. Here is the code I add to the grid:

.SetAdditionalAttributes("}).filterToolbar({ stringResult: true, searchOnEnter: false, multipleSearch:true ")

The error I get is: expected identifier, string or number

Jun 15, 2011 at 7:23 AM

I know I'm tiring you with this answer, but this is yet another feature planned for the upcoming release.
In the meantime, I suggest you use a different approach instead of (the somewhat hackish) AdditionalAttributes:

@Html.Grid(new GridControl().SetName("grid")

<script language="javascript" type="text/javascript">
function initGridToolbar()
    $("#grid").filterToolbar({stringResult:true, searchOnEnter: false, multipleSearch:true});

This works on IE7 as well.

Jun 15, 2011 at 2:57 PM

The problem I have with the above implementation is that a new filterToolbar gets added to the grid on each refresh of the grid.

Jun 15, 2011 at 3:24 PM

Yes, I'll have to add an event-callback after the grid finished initial rendering (and not in subsequent refreshes).
In the mean time you could use a first time flag in the initGridToolbar. (I know I know...)