This question is locked. New answers and comments are not allowed.
Hi all,
I'm new to this and for now just playing with grid and access database.
Here is code from Index.asp :
And here is code from HomeController:
Question is how to add grouping in code?
I'm new to this and for now just playing with grid and access database.
Here is code from Index.asp :
<%= Html.Telerik().Grid<System.Data.DataRow>(Model.Rows.Cast<System.Data.DataRow>()) .Name("Grid") .Columns(columns => { foreach (System.Data.DataColumn column in Model.Columns) { columns.Bound(column.DataType, column.ColumnName); } }) .HtmlAttributes( new { style="height:500px"}) .Scrollable(scrolling => scrolling.Height(410)) .Pageable(paging => paging.PageSize(20)) .Sortable() .Scrollable() .Groupable() %> <%= Html.Telerik().ScriptRegistrar() %>private DataTable Model() { OleDbConnection myCon = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=E:\\Nwind.mdb;Persist Security Info=False"); DataSet myDS = new DataSet(); OleDbCommand MyCmd = new OleDbCommand("SELECT * FROM Customers", myCon); OleDbDataAdapter myDA = new OleDbDataAdapter(MyCmd); myCon.Open(); myDA.Fill(myDS, "Customers"); return myDS.Tables["Customers"] ; }