We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Grid Hierarchy - Child table dosen't show

Thread ID:





112483 Sep 25,2013 06:14 AM UTC Oct 7,2013 04:41 AM UTC ASP.NET MVC (Classic) 4
Tags: Grid
Jacob Saugmann
Asked On September 25, 2013 06:14 AM UTC


Ive created at Hierarchy grid and the grid shows just fine in my .aspx page

But when i press the row to se the child table i get this:

When i debug my code i can see that the ActionResult ChildGrid does return a result

I've hidden the row where the id is for joining but it is passed to the code behind
What am i doing wrong?

My aspx:
   @{ Html.Syncfusion().Grid<DataRow>("GridSrc").Datasource(Model)
               .ChildGrid(child => child.ChildGridTemplate(Html.Syncfusion().Grid<DataRow>("ChildGrid_${JoinId}").Caption("Overblik over hændelser").Mappers(map => map.Action("ChildGrid", new { joinid = "${JoinId}" })).ToChildGridTemplate())).ClientSideEvents(events => { events.OnLoad("hideGridColumn"); }).Render();

My codebehind:
        public ActionResult ChildGrid(PagingParams args, string joinid)
            DataTable table = new DataTable("Hændelser");

            using (SqlConnection sqlCon = new SqlConnection(_sqlConString))
                    string sqlCmdQuery = @"SELECT
                                                Maaned ,
                                                Aar ,
                                                Start_Dato ,
                                                Slut_Dato ,
                                                Type ,
                                                Varighed ,
                                        FROM Statistik.VW_OverblikAlleHaendelser AS VOAH
                                        WHERE VOAH.JoinId = '" + joinid +
                                         "' ORDER BY Start_Dato";
                    SqlCommand sqlCmd;

                    sqlCmd = new SqlCommand(sqlCmdQuery);
                    sqlCmd.Connection = sqlCon;


                    SqlDataAdapter sqlDataAdapter = new SqlDataAdapter(sqlCmd);

                catch (Exception exception)

                    if (sqlCon.State == ConnectionState.Open)

            IEnumerable data = table.AsEnumerable().ToList();
            return data.GridActions<DataRow>();




Hariharan J V [Syncfusion]
Replied On September 30, 2013 10:44 AM UTC

Hi Jacob,

Thanks for using Syncfusion products.

Currently we are analyzing on this issue and we will update you on two business days.

Please let us know if you need any further assistance.

Hariharan J.V.

Bala Murugan A.S [Syncfusion]
Replied On October 3, 2013 12:39 PM UTC

Hi Jacob,


Thanks for your patience.


We suggest you to set datasource for child grid initially to avoid your issue. Please refer the below code snippets.



  .ChildGrid(child =>
                            .Caption("OrderDetails Grid")
                            .Mappers(map =>
                                map.Action("ChildGrid", new { OrderID = "${OrderID}" });



 public ActionResult Index()
            ViewData["data"] = GetTable1(GetTable().Rows[0]["OrderID"].ToString()).AsEnumerable();
            return View(GetTable());


For your convenience, we have prepared a simple sample to demonstrate this and the same can be downloaded from the below link.


Sample: DataTable_Hierarchygrid.zip


Could you please check the above sample and let us know if this is helpful.


Please let us know if you need further assistance.



Balamurugan A.S

Jacob Saugmann
Replied On October 4, 2013 09:26 AM UTC


It worked :-)

Thanks you for your help :-)


Hariharan J V [Syncfusion]
Replied On October 7, 2013 04:41 AM UTC

Hi Jacob,

Thanks for your update.

We are glad to know that your issue has been resolved. Please let us know if you have any other concerns so that we will be happy to help you out.

Hariharan J.V.


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon