Over the last few days, i've been fighting an issue with editable cell focus as it relates to a grid that is loaded into a window. Here is an example of the code I am working with:
When the window is loaded, it will render a view that results from LoadContentFrom(). The grid shows up and has all the correct data as expected. When a click is made into one of the editable fields, it toggles over into the editor view as expected; however, any subsequent click in the cell will cause it to lose focus and return to its viewer template. As a test case, I took the grid code and moved it into my index view and the issue is then resolved; as such, I find that it only occurs when the grid is loaded within a window.
I am experiencing this issue only in IE (all versions). Firefox and Chrome both appear to be operating as expected.
@{ Html.Kendo().Window() .Name("popupwindow") .Title("Title Of Window") .Draggable() .LoadContentFrom("MyAction","MyController") .Draggable(true) .Width(800) .Modal(true) .Scrollable(true) .Visible(false) .Render();}@( Html.Kendo().Grid<MyProject.ViewModels.MyObject>() .Name("MyGrid") .Columns(col => { col.Bound(p => p.ID); col.Bound(p => p.SomeField); col.ForeignKey(p => p.SomeOtherID,(System.Collections.IEnumerable)ViewBag.ListOptions, "Value", "Text"); }) .Editable(edit => edit.Mode(GridEditMode.InCell)) .Scrollable() .DataSource(ds => ds.Ajax() .ServerOperation(false) .Model(model => { model.Id(p => p.ID); model.Field(p => p.SomeOtherID).DefaultValue(0); }) .Read("_Read", "MyController") .Update("_Update", "MyController") ) .ToolBar(tool => {
// Removed for this post }))When the window is loaded, it will render a view that results from LoadContentFrom(). The grid shows up and has all the correct data as expected. When a click is made into one of the editable fields, it toggles over into the editor view as expected; however, any subsequent click in the cell will cause it to lose focus and return to its viewer template. As a test case, I took the grid code and moved it into my index view and the issue is then resolved; as such, I find that it only occurs when the grid is loaded within a window.
I am experiencing this issue only in IE (all versions). Firefox and Chrome both appear to be operating as expected.