Product Bundles
DevCraft
All Telerik .NET and Kendo UI JavaScript components and AI Tools in one package.
Kendo UI
Bundle of AI Tools plus four JavaScript UI libraries built natively for jQuery, Angular, React and Vue.
Build JavaScript UI
Javascript
Telerik
Build modern .NET business apps
.Net Web
Cross-Platform
Desktop
Reporting and Documents
AI for Developers & IT
Ensure AI program success
AI Coding
AI Engineering
Additional Tools
Enhance the developer and designer experience
Testing & Mocking
Debugging
UI/UX Tools
CMS
Free Tools
Support and Learning
Productivity and Design Tools
HI, I'm using rad grid with grouping, i've grouped two columns.
Now i want to give two different colors to those two grouped (App Type, Status) columns.
I need Black color font for Status and Blue color font for App Type.
How to achieve this, please help.
Thanks
Hi Chakradhar,
You can use the ItemDataBound event to get access to each GroupHeaderItem and set its ForeColor conditionally.
For instance:
protected void RadGrid1_ItemDataBound(object sender, GridItemEventArgs e) { var groupHeaderItem = e.Item as GridGroupHeaderItem; if (groupHeaderItem != null) { if (groupHeaderItem.DataCell.Text.StartsWith("App Type")) { groupHeaderItem.ForeColor = Color.Blue; } else if (groupHeaderItem.DataCell.Text.StartsWith("Status")) { groupHeaderItem.ForeColor = Color.Black; } } }
You may also find it useful to check out the Customizing GridGroupHeaderItem article.
I hope this will help you achieve the desired.
Please let me know if any further questions come up.
Kind regards, Doncho Progress Telerik
Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.