Click here to Skip to main content
15,914,013 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Problem changing proxy with custom IE toolbar Pin
Matthew Devine8-Jul-05 3:01
Matthew Devine8-Jul-05 3:01 
GeneralRe: Problem changing proxy with custom IE toolbar Pin
Jose Lamas Rios8-Jul-05 7:17
Jose Lamas Rios8-Jul-05 7:17 
GeneralRe: Problem changing proxy with custom IE toolbar Pin
Matthew Devine12-Jul-05 2:23
Matthew Devine12-Jul-05 2:23 
GeneralClosing a dialog app window Pin
jerry1211a7-Jul-05 10:02
jerry1211a7-Jul-05 10:02 
GeneralRe: Closing a dialog app window Pin
Ravi Bhavnani7-Jul-05 10:26
professionalRavi Bhavnani7-Jul-05 10:26 
GeneralRe: Closing a dialog app window Pin
PJ Arends7-Jul-05 10:49
professionalPJ Arends7-Jul-05 10:49 
GeneralTranslation Tool Pin
transoft7-Jul-05 8:28
transoft7-Jul-05 8:28 
GeneralRe: Translation Tool Pin
Ravi Bhavnani7-Jul-05 10:28
professionalRavi Bhavnani7-Jul-05 10:28 
Generala poker game....need help......plz help Pin
koalacui7-Jul-05 7:55
koalacui7-Jul-05 7:55 
GeneralRe: a poker game....need help......plz help Pin
David Crow7-Jul-05 8:06
David Crow7-Jul-05 8:06 
GeneralRe: a poker game....need help......plz help Pin
koalacui7-Jul-05 8:11
koalacui7-Jul-05 8:11 
GeneralI have done so far..............help me update Pin
koalacui7-Jul-05 8:13
koalacui7-Jul-05 8:13 
QuestionHow to check folder last access time? Pin
MirkoMax7-Jul-05 7:39
sussMirkoMax7-Jul-05 7:39 
AnswerRe: How to check folder last access time? Pin
David Crow7-Jul-05 7:48
David Crow7-Jul-05 7:48 
Generalcheckbox check problem Pin
c. s.7-Jul-05 7:11
c. s.7-Jul-05 7:11 
GeneralRe: checkbox check problem Pin
David Crow7-Jul-05 7:32
David Crow7-Jul-05 7:32 
GeneralRe: checkbox check problem Pin
c. s.7-Jul-05 7:49
c. s.7-Jul-05 7:49 
GeneralRe: checkbox check problem Pin
David Crow7-Jul-05 8:02
David Crow7-Jul-05 8:02 
GeneralRe: checkbox check problem Pin
c. s.7-Jul-05 8:09
c. s.7-Jul-05 8:09 
GeneralRe: checkbox check problem Pin
David Crow7-Jul-05 8:14
David Crow7-Jul-05 8:14 
GeneralRe: checkbox check problem Pin
Jose Lamas Rios7-Jul-05 8:08
Jose Lamas Rios7-Jul-05 8:08 
c. s. wrote:
hTempWnd = CreateWindowEx (
0, // no extended style
"Button",
"Compression", // toggles chunk compression
WS_VISIBLE | WS_CHILD | BS_OWNERDRAW, // make a visible child window, that we draw ourself (see void DrawCheckbox)
clientRect.right - MM_DBUTTON_WIDTH - MMPADDING_RIGHT, // create it near the top right corner
clientRect.top + MMPADDING_TOP + MM_GROUPPADDING_BOTTOM,
MM_DBUTTON_WIDTH, MM_DBUTTON_HEIGHT, // use our standard checkbox button height and width
hWnd, // our parent window is this popup menu
(HMENU) MMENU_BUTTON_COMPRESSION,
GetModuleHandle ( NULL ),
NULL // pass no extra parms on creation
) ;


According to this[^], an owner-drawn button "has no predefined appearance or usage. Its purpose is to provide a button whose appearance and behavior are defined by the application alone."

Furthermore, your call to Create isn't even specifying one of the possible check box styles (BS_CHECKBOX, BS_AUTOCHECKBOX, BS_3STATE, BS_AUTO3STATE), so it's no wonder the control doesn't react to BM_SETCHECK messages. Try adding BS_CHECKBOX, and if that doesn't work (which may be due because of the owner draw style), I suggest subclassing the control so that you can handle the BM_GETCHECK and BM_SETCHECK messages yourself.

Hope that helps,

--
jlr
http://jlamas.blogspot.com/[^]
GeneralRe: checkbox check problem Pin
David Crow7-Jul-05 8:15
David Crow7-Jul-05 8:15 
GeneralRe: checkbox check problem Pin
Jose Lamas Rios7-Jul-05 8:20
Jose Lamas Rios7-Jul-05 8:20 
GeneralRe: checkbox check problem Pin
c. s.7-Jul-05 8:18
c. s.7-Jul-05 8:18 
GeneralRe: checkbox check problem Pin
Jose Lamas Rios7-Jul-05 8:40
Jose Lamas Rios7-Jul-05 8:40 

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.