You can remove the (+) sign in rows that do not have any child rows.
In this topic, you will learn how to perform the above scenario.
To remove (+) sign for rows that contain no child row
- Add the following code under InitializeRow event handler.
C# Copy Code protected void WebGrid1_InitializeRow(object sender, ISNet.WebUI.WebGrid.RowEventArgs e) { if (e.Row.GetChildTableRows(e.Row.Table.ChildTables[0]).Count == 0) e.Row.ChildNotExpandable = true; }
- Compile and run the WebForm.