Whenever I put HTML into the Group Header Item, as per Telerik instruction, eroneous "<p> </p>"
tags are being inserted above and below my content.
If I just have plain text (ie not HTML) then I don't get this behavour.
I need to use HTML to format my data/text.
This is my code, using literal but it didnt make any difference whether directly or via the literal.
tags are being inserted above and below my content.
If I just have plain text (ie not HTML) then I don't get this behavour.
I need to use HTML to format my data/text.
This is my code, using literal but it didnt make any difference whether directly or via the literal.
protected void gridResults_ItemDataBound(object sender, Telerik.Web.UI.GridItemEventArgs e){ if (e.Item is GridGroupHeaderItem) { StringBuilder sb = new StringBuilder(); sb.Append("<div style=\"width:500px; overflow-x:auto; overflow-y:hidden; \">"); sb.Append(" <div style=\"width:400px;\">"); sb.Append(" <div style=\"width:100px; float:left;\">Name </div>"); sb.Append(" <div style=\"width:100px; float:left;\">Year Level </div>"); sb.Append(" <div style=\"width:100px; float:left;\">Classes </div>"); sb.Append(" </div>"); // row. sb.Append("</div>"); // table. GridGroupHeaderItem groupHeaderItem = (GridGroupHeaderItem)e.Item; Literal literal = new Literal(); literal.Text = sb.ToString(); groupHeaderItem.DataCell.Controls.Add(literal); }}