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

[Solved] Grid with ajaxEditing enable doesn't work in partial view when it's loaded first time by ajax f

2 Answers 69 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.
cheng
Top achievements
Rank 1
cheng asked on 31 Oct 2010, 01:23 AM
Grid with ajaxEditing enable doesn't work in partial view when it's loaded first time by another  partial view,which uses  jQuery "$('#xxx').load(url)" to load the partial view including a Grid with editable and command edit column;
A error display when it's loaded first time says: "a[...] is null or not an object"
It's weird that when I click that jQuery load  link  second time , the grid partial view do work normally.
I have tried to remove the command column ,and all thing seems to be normal again . 

I've searched the forum and founded a post mentioning  about this issue , and  according that post I added "Html.Telerik().ScriptRegistrar()" code snippet to the end of the partial view . It didn't resoved this issue as well.

Any one have any idea?

thanks first!
        .Add("telerik.grid.editing.min.js")
        .Compress(true)
       )
       .jQuery(false)
       .Render(); %>
<% Html.Telerik().ScriptRegistrar()
        .DefaultGroup(group => group
        .Add("telerik.common.min.js")
        .Add("telerik.grid.min.js")
        .Add("jquery.validate.min.js")
        .Add("telerik.grid.editing.min.js")
        .Compress(true)
       )
       .jQuery(false)
       .Render(); %>
<% Html.Telerik().ScriptRegistrar()
        .DefaultGroup(group => group
        .Add("telerik.common.min.js")
        .Add("telerik.grid.min.js")
        .Add("jquery.validate.min.js")
        .Add("telerik.grid.editing.min.js")
        .Compress(true)
       )
       .jQuery(false)
       .Render(); %>
<% Html.Telerik().ScriptRegistrar()
        .DefaultGroup(group => group
        .Add("telerik.common.min.js")
        .Add("telerik.grid.min.js")
        .Add("jquery.validate.min.js")
        .Add("telerik.grid.editing.min.js")
        .Compress(true)
       )
       .jQuery(false)
       .Render(); %>

2 Answers, 1 is accepted

Sort by
0
cheng
Top achievements
Rank 1
answered on 31 Oct 2010, 01:26 AM
Ps ,I load the grid partial view to a <div> tag and open a jQuery dialog to display it.
0
cheng
Top achievements
Rank 1
answered on 31 Oct 2010, 08:35 AM

Well, I've just fixed this issue by placing  ""Html.Telerik().ScriptRegistrar().jQuery(false)""  at the end of the first partial view ,

I'd placed it  at the second level partial view .
Tags
Grid
Asked by
cheng
Top achievements
Rank 1
Answers by
cheng
Top achievements
Rank 1
Share this question
or