Solved

Change the 'progress' color of a CProgressCtrl.

Posted on 1998-08-26
1
316 Views
Last Modified: 2013-11-19
Can anyone tell me how to change the 'progress' color of a CProgressCtrl.  The doc says that it is displayed as the system highlight color but changing that seems risky.  (lol)

Zerb.

0
Comment
Question by:TXTX
1 Comment
 
LVL 2

Accepted Solution

by:
prasanth earned 100 total points
ID: 1321322
You need to get the latest version of the progress control from
http://msdn.microsoft.com/developer/downloads/files/40Comupd.htm and send a PBM_SETBARCOLOR message to it. The lParam is the COLORREF to use.

#define PBM_SETBARCOLOR         (WM_USER+9)

// for a red progress bar
SendMessage(hwndProgress, PBM_SETBARCOLOR, 0, RGB(255, 0, 0));

0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Suggested Solutions

In this article, I'll describe -- and show pictures of -- some of the significant additions that have been made available to programmers in the MFC Feature Pack for Visual C++ 2008.  These same feature are in the MFC libraries that come with Visual …
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.
This video discusses moving either the default database or any database to a new volume.

759 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

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now