Click here to Skip to main content
15,906,628 members
Home / Discussions / ATL / WTL / STL
   

ATL / WTL / STL

 
QuestionHow to access member functions of coclass from its Interface Pin
mandanani8-Jan-08 16:51
mandanani8-Jan-08 16:51 
AnswerRe: How to access member functions of coclass from its Interface Pin
mandanani8-Jan-08 20:41
mandanani8-Jan-08 20:41 
GeneralRe: How to access member functions of coclass from its Interface Pin
Nathan Holt at EMOM9-Jan-08 10:02
Nathan Holt at EMOM9-Jan-08 10:02 
GeneralCOM object and global pointers [modified] Pin
Monty27-Jan-08 21:54
Monty27-Jan-08 21:54 
GeneralRe: COM object and global pointers Pin
led mike8-Jan-08 5:04
led mike8-Jan-08 5:04 
GeneralOleDb, IRowsetIndex Pin
ArielR7-Jan-08 3:38
ArielR7-Jan-08 3:38 
GeneralStatic controls transparency problem Pin
mirano6-Jan-08 10:19
mirano6-Jan-08 10:19 
GeneralRe: Static controls transparency problem Pin
Michael Dunn6-Jan-08 11:05
sitebuilderMichael Dunn6-Jan-08 11:05 
You're returning HOLLOW_BRUSH which paints nothing. When the control asks you what brush to use as the background brush, you give it a brush that doesn't paint, so the old contents of the control aren't erased. I'd do this:
LRESULT MainDialog::OnCtlColorStatic(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
{
HWND hWnd = (HWND) lParam;
HDC hDc = (HDC) wParam;
 
  if(hWnd == GetDlgItem(IDC_FILE) || hWnd == GetDlgItem(IDC_FILESIZE))
    {
    SetTextColor(hDc, RGB(128,0,0));
    SetBkMode(hDc, TRANSPARENT);
    }
 
  bHandled = false;
  return 0;
}
This code changes the attributes of the DC that you care about, then lets the message go on to the default window proc, which will set the right background color.


--Mike--
Visual C++ MVP Cool | :cool:
LINKS~! CP SearchBar v3.0 | C++ Forum FAQ

Dunder-Mifflin, this is Pam.

GeneralRe: Static controls transparency problem Pin
mirano6-Jan-08 11:52
mirano6-Jan-08 11:52 
GeneralRe: Static controls transparency problem [modified] Pin
Michael Dunn6-Jan-08 12:09
sitebuilderMichael Dunn6-Jan-08 12:09 
GeneralRe: Static controls transparency problem Pin
mirano7-Jan-08 0:34
mirano7-Jan-08 0:34 
GeneralMSMQ Pin
shakumar_221-Jan-08 22:27
shakumar_221-Jan-08 22:27 
QuestionCInternetSession Assertion Failure Pin
İsmail Durmaz22-Dec-07 7:30
İsmail Durmaz22-Dec-07 7:30 
GeneralNamespace ATL Pin
Ju@ncho19-Dec-07 7:00
Ju@ncho19-Dec-07 7:00 
GeneralNeed to launch outlook Pin
SamuelHenderson18-Dec-07 5:37
SamuelHenderson18-Dec-07 5:37 
QuestionWhere did the WTL documentation project go? Pin
Perceptor18-Dec-07 3:33
Perceptor18-Dec-07 3:33 
GeneralA strange WTL-app debug/release problem [modified] Pin
T800G14-Dec-07 15:06
T800G14-Dec-07 15:06 
GeneralRe: A strange WTL-app debug/release problem Pin
CPallini28-Dec-07 11:45
mveCPallini28-Dec-07 11:45 
QuestionWTL COM? Pin
Kuryn13-Dec-07 23:17
Kuryn13-Dec-07 23:17 
AnswerRe: WTL COM? Pin
George L. Jackson14-Dec-07 4:44
George L. Jackson14-Dec-07 4:44 
GeneralRe: WTL COM? Pin
Kuryn15-Dec-07 18:12
Kuryn15-Dec-07 18:12 
GeneralRe: WTL COM? Pin
George L. Jackson16-Dec-07 14:23
George L. Jackson16-Dec-07 14:23 
AnswerRe: WTL COM? Pin
led mike18-Dec-07 5:29
led mike18-Dec-07 5:29 
AnswerRe: WTL COM? Pin
Michael Dunn5-Jan-08 20:36
sitebuilderMichael Dunn5-Jan-08 20:36 
GeneralWindows Service Help [modified] Pin
narayanagvs10-Dec-07 19:02
narayanagvs10-Dec-07 19:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.