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

[Solved] how bind grid ?

1 Answer 15 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.
javad
Top achievements
Rank 1
javad asked on 14 Jul 2011, 03:56 PM
i use this code


<%: Html.Telerik().Grid<TelerikMvcApplication1.Models.Customer>()
        .Name("Grid")
       
        .Columns(columns =>
        {
            columns.Bound(o => o.CustomerID_FK).Width(100);
            columns.Bound(o => o. CustomerName).Width(200);
            columns.Bound(o => o.CustomerFullName);
            columns.Bound(o => o.CostomerNO);
        })

            .DataBinding(dataBinding => dataBinding.Ajax().Select("Index", "Customer"))
%>


and controller is

 public ActionResult Index()
        {
            Entities en = new Entities();
            var c = en.Customers;
            return View(c);
        }


but do not show customers in grid
and show this error:
Error! The requested URL did not return JSON.

1 Answer, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 14 Jul 2011, 04:02 PM
Hello Javad, 

You could check the following resources:


Regards,
Atanas Korchev
the Telerik team

Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

Tags
Grid
Asked by
javad
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Share this question
or