Colouring The ComboBox Text

vb6 , combo , colour , text India
  • 12 years ago
    Hai, My dear members of developerFusion, Can anybody could let me know how to change the desired colour of Text in a combo box when Enter key is pressed. A particular text in the combo box must turn into any of the colours, i.e., all the other text that is displayed in the box must be in the default colour, only when I press Enter key, the particular text that is displayed in the combo box at the time of me clicking the combo box must get some colour say green or red or blue. I am able to get the forecolour in the combo box but all the other texts in the combo box is displaying the same colour. When I drop down the combo box text's the particular text on which I pressed Enter Key must be displayed in any of the assigned colour. One more small pro I request you people, is that I want to get the combo box's text (The one i'e., displayed or any of the text's in the combo box) must get some colour when I click on a particular row in MSFlexGrid (That correspond's to the Combo Box text.). I am able to get the Text from combo box into the MSFlexGrid when I press Enter key, but am unable to get the particular text coloured when I click a particular row in MSFlexGrid. For Ex: One of the rows in MSFlexGrid show somepersons name say Jithender, which is also one of the text's in the combo box. If I click the Jithender row in MSFlexGrid then the same text that is in the combo box must get any of the colours say either green or red. (Hope it's clear to you all, what I mean to say and want to get) Will any of you please help me out and that too in simple pro lang. I am eagerly waiting for a prompt reply from many of you. Thanks and best wishes,(For Loop) E.Jithender.

Post a reply

No one has replied yet! Why not be the first?

Sign in or Join us (it's free).


Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“Some people, when confronted with a problem, think "I know, I’ll use regular expressions." Now they have two problems.” - Jamie Zawinski