tags:

views:

61

answers:

2

I have a Telerik MVC Tabstrip.

I have used:

.LoadContentFrom("Grid", "Orders");

"Grid" Action just returns view without model. Then the Ajax request should have been fired to get the data.

It is loading the grid normally but it is not calling the Ajax request to fill the data. If I am calling the same action normally i.e. without ajax it displays grid and fires Ajax request to load the data.

A: 

Perhaps you've missed to register the required JavaScript files for the Grid. You can check the following help topics:

korchev
Did you register the JavaScript files of the Grid in your view (NOT the partial view)? This is the only thing required. The ScriptRegistrar does not work in partial views loaded with Ajax. If still having issues you can provide a sample project or paste all the code.
korchev
Not working. I added <%=Html.Telerik().ScriptRegistrar().DefaultGroup(group => group.Add("telerik.common.js").Add("telerik.grid.js"))%>To main View(master). Still same issue. I wont bother you further. The snippets are from a a project where it is not just MVC. I am working on sharpArch + Spark. So I will create a new project with Pure MVC and test the above if it works and then upload th code.
Sachin
@korchev. I have made changes in the Example code provided by Telerik download. I have added the changes as new answer for your reference.Please correct me where I am wrong.
Sachin
You have not included all required files. Date time columns require telerik.calendar.js and telerik.datepicker.js. Either remove the date time column or include those files. Also check in the generated output that the javascript files are included in the right order. That order can be seen in the Required JavaScript files help topic.
korchev
Added all required js. Confirmed the load order.Still no luck
Sachin
A: 

Check the sample available at here.

This one uses MVC 1.0 but can be surely converted to MVC 2.0

Sachin