GIDForums  

Go Back   GIDForums > Computer Programming Forums > MS Visual C++ / MFC Forum
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread Rate Thread
  #1  
Old 18-Mar-2009, 11:55
Liartes Liartes is offline
New Member
 
Join Date: Mar 2009
Posts: 1
Liartes is on a distinguished road

Problems with SetCheck


Hi,

I have a check button in a CPropertyPage. It needs to change it's state based on data from the item selected from a list box. I've done similar things in other places and haven't had any problems using:

if( someBool )
m_cButton.SetCheck(BST_CHECKED);
else
m_cButton.SetCheck(BST_UNCHECKED);

in the event handler for list selection change, where m_cButton is bound in DoDataExchange.

For some reason however when I do this here it always unchecks the button, no matter the value passed to SetCheck, which I've checked in the debugger. I have also tried CheckDlgButton and (CButton*)GetDlgItem(IDC_CHECKID)->SetCheck but get the same result.

Does anyone have any idea what could be causing this?

Thanks for any help.
 
 

Recent GIDBlogProblems with the Navy (Enlisted) by crystalattice

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
IE 7 Problems colliegirl Computer Software Forum - Windows 6 05-Jun-2008 08:10
Recent problems with antivirus programmes steven_symantec Member Announcements, Advertisements & Offers 3 14-Feb-2008 21:22
Problems while burning CD's netnut Computer Software Forum - Windows 16 17-Jan-2008 23:45
Chaintech Geforce 5600 FX problems bartster74 Computer Hardware Forum 8 04-May-2004 13:16
Serious Problems: Exabyte Products and Service pkazmercyk@comc Computer Hardware Forum 2 05-Feb-2004 07:59

Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The

All times are GMT -6. The time now is 07:11.


vBulletin, Copyright © 2000 - 2010, Jelsoft Enterprises Ltd.