This is a migrated thread and some comments may be shown as answers.

[Solved] Grid fails when tab on a checkbox cell in IE8

1 Answer 94 Views
Grid
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Oscar
Top achievements
Rank 1
Oscar asked on 17 Oct 2011, 02:12 PM
I have a grid with .keyboardNavigation enabled(True) and EditOnTab(True).
When you tab on a cell which clientTemplate is an input type='checkbox', _clearInputSelection function in telerik.grid.js gives an exception in sentence:
 range = input.createTextRange()

Is there any workaround?

1 Answer, 1 is accepted

Sort by
0
Accepted
Nikolay Rusev
Telerik team
answered on 18 Oct 2011, 08:37 AM
Hello Oscar,

Unfortunately you are right. We will do our best to have this issue fixed as soon as posible in one of the next latest internal builds.

I have also updated your Telerik points.

As a temporary solution you can use the following code snippet.
<%Html.Telerik().ScriptRegistrar()
    .OnDocumentReady(() =>
    {
        %>           
            $.telerik.grid.prototype._clearInputSelection = function(input) {
                if(!input || $(input).is(":checkbox, :radio")) {
                    return;
                }
                var browser = $.browser,
                    range;
                if(browser.msie && parseInt(browser.version) == 8) {
                    range = input.createTextRange();
                    range.moveStart('textedit', 1);
                    range.select();
                }
            }       
        <%
    });
%>


Greetings,
Nikolay Rusev
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the Telerik Extensions for ASP.MET MVC, subscribe to their blog feed now
Tags
Grid
Asked by
Oscar
Top achievements
Rank 1
Answers by
Nikolay Rusev
Telerik team
Share this question
or