Solved

Different colored text in ComboBox without Subclassing

Posted on 2010-11-28
8
73 Views
Last Modified: 2016-05-28
How to display multi colored text based on the added string  in the combobox(MFC) without subclassing

Thanks in advance
0
Comment
Question by:Harishsona
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
8 Comments
 
LVL 44

Accepted Solution

by:
AndyAinscow earned 500 total points
ID: 34228281
Impossible.  You need to subclass
0
 

Author Comment

by:Harishsona
ID: 34228433
Ok, with subclassing want to change text color for already added items or while adding the text based on string (Ex., Prefix "$" should get the RED Color and remaining normal)
0
 
LVL 44

Assisted Solution

by:AndyAinscow
AndyAinscow earned 500 total points
ID: 34228448
Well your original question was answered but here is an example about owner drawing a combo

http://www.experts-exchange.com/Programming/System/Windows__Programming/MFC/Q_24111090.html

Just check which item you want to display and change the foreground (=text) colour as required.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 11

Expert Comment

by:DeepuAbrahamK
ID: 34359821
0
 
LVL 8

Expert Comment

by:Pramod Bugudai
ID: 38621177
Why don't you assign the points to AndyAinscow? He has already answered your question plus gave some extra ideas for your another question. I suggest ask these questions in a new thread.
0
 

Expert Comment

by:EE_AutoDeleter
ID: 41619422
I've requested that this question be deleted for the following reason:

                           
No comment has been added to this question in more than 21 days, so it is now classified as abandoned and is now flagged for deletion.


If there is a valid solution, please OBJECT and indicate the comments that are, or would otherwise lead to, a solution.


Use the specific format https:#axxxxxxxx for comment ID(s).


Also, please don't object simply because the author did not respond to your comment. While we understand this is frustrating, unfortunately we cannot force the author to return to the question. Unless you feel you have presented a valid, verifiable solution we'll simply delete the question.


Experts-Exchange Auto Deleter
0
 
LVL 44

Expert Comment

by:AndyAinscow
ID: 41619423
Question is answered here.  https:#a34228281
Link to drawing subclassed combobox.  https:#a34228448
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Finishing the grid – keyboard support for arrow keys to manoeuvre, entering the numbers.  The PreTranslateMessage function is to be used to intercept and respond to keyboard events. Continuing from the fourth article about sudoku. …
Introduction: Dialogs (2) modeless dialog and a worker thread.  Handling data shared between threads.  Recursive functions. Continuing from the tenth article about sudoku.   Last article we worked with a modal dialog to help maintain informat…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question