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

ComboBoxAdv missing OwnerDraw and DrawItem

Thread ID:





119405 Jun 16,2015 08:41 PM UTC Jun 17,2015 11:23 AM UTC WinForms 4
Tags: ComboBoxAdv
Asked On June 16, 2015 08:41 PM UTC

I am creating a comboBox to show a list of line thickness items.
With the conventional MS ComboBox I can set to OwnerDraw and then call DrawItem to create line thickness examples directly on the combo's initial draw.

It seems that the ComboBoxAdv is missing OwnerDraw and DrawItem.
Yes I can work around by creating another loop to create images and then loop through to add the images to the ComboBoxAdv, but that's about as clunky as a Model A Ford.

Replied On June 16, 2015 08:50 PM UTC

...just to further explain why I want DrawItem. The line thickness graphics are created on the fly in the same color that the operator had selected ...just so the operator gets a nice warm fuzzy feeling.

Ashwini Jaya Preetha Durai Samy [Syncfusion]
Replied On June 17, 2015 10:57 AM UTC

Hi Vince,

Thank you for using Syncfusion products.

This reported requirement for customizing ComboBoxAdv items can be achieved by using DrawMode property and DrawItem event in ComboBoxAdv ListBox. Please refer the below code snippet for your reference.

Code snippet [C#]:

// DrawMode in ComboBoxAdv

this.comboBoxAdv1.ListBox.DrawMode = DrawMode.OwnerDrawFixed;

//DrawItem event in ComboBoxAdv
comboBoxAdv1.ListBox.DrawItem += new DrawItemEventHandler(ListBox_DrawItem);

We have also prepared a sample for your reference and it can be downloaded from the following location.

Sample Location: http://www.syncfusion.com/downloads/support/forum/119405/ze/ComboBoxAdvDrawItem-1319896049

Please look into the sample and kindly let us know if it helps.


Replied On June 17, 2015 11:17 AM UTC



Ashwini Jaya Preetha Durai Samy [Syncfusion]
Replied On June 17, 2015 11:23 AM UTC

Hi Vince,

Thank you for your update.

We are glad that we have helped you on this.

Please let us know if you need any further assistance,



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

or the page will be automatically redirected to 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