Solved

Change the 'progress' color of a CProgressCtrl.

Posted on 1998-08-26
1
319 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

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say 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: Displaying information on the statusbar.   Continuing from the third article about sudoku.   Open the project in visual studio. Status bar – let’s display the timestamp there.  We need to get the timestamp from the document s…
Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
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.

790 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