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: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to change WinForms MultiColumnComboBox row colors?

Thread ID:

Created:

Updated:

Platform:

Replies:

152520 Mar 18,2020 08:19 AM UTC Mar 24,2020 04:24 AM UTC WinForms 3
loading
Tags: MultiColumnComboBox
Dinis Ferreira
Asked On March 18, 2020 08:19 AM UTC

Hi,
Is it possible to change color in MultiColumnComboBox rows or cells? Like row or cell backcolor, text color, header backcolor or text color?
I can't find any threads about this...
Thanks

Duraimurugan Vedagiri [Syncfusion]
Replied On March 19, 2020 12:35 PM UTC

Hi Dinis,

Thanks for using syncfusion products.

We have analyzed your reported requirement "Is it possible to change the row color in MultiColumnComboBox?" and you can achieve by using PrepareViewStyleInfo event.

Please refer the below code snippet and screenshot for your reference.

 
GridControl grid = this.multiColumnComboBox1.ListBox.Grid; 
grid.PrepareViewStyleInfo += Gc_PrepareViewStyleInfo; 
  
private void Gc_PrepareViewStyleInfo(object sender, GridPrepareViewStyleInfoEventArgs e) 
{ 
    if (e.RowIndex == 0) 
    { 
        e.Style.BackColor = Color.Black; 
        e.Style.TextColor = Color.White; 
    } 
} 
  
Screen Shot

 
  
Regards,
Durai 





Dinis Ferreira
Replied On March 20, 2020 11:43 AM UTC

Hello,
It works very good.
Thank you.

Duraimurugan Vedagiri [Syncfusion]
Replied On March 24, 2020 04:24 AM UTC

Hi Dinis,

Thanks for you update.

We are glad to know that you are achieve your requirement at your end. Please let us know if you need any further assistance.

Regards,
Durai

CONFIRMATION

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

Live Chat Icon For mobile
Live Chat Icon