Click here to Skip to main content
15,895,256 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: const Pin
Anthony_Yio24-Sep-03 17:12
Anthony_Yio24-Sep-03 17:12 
GeneralManually implement LVSCW_AUTOSIZE_USEHEADER Pin
Wim Jans24-Sep-03 10:32
Wim Jans24-Sep-03 10:32 
GeneralRe: Manually implement LVSCW_AUTOSIZE_USEHEADER Pin
David Crow24-Sep-03 10:39
David Crow24-Sep-03 10:39 
GeneralRe: Manually implement LVSCW_AUTOSIZE_USEHEADER Pin
Wim Jans24-Sep-03 10:49
Wim Jans24-Sep-03 10:49 
GeneralScrollbars in a dynamically changing dialog Pin
Member 53435724-Sep-03 10:15
Member 53435724-Sep-03 10:15 
GeneralVC++ Debugger Pin
yanmei24-Sep-03 9:56
yanmei24-Sep-03 9:56 
GeneralRe: VC++ Debugger Pin
Neville Franks24-Sep-03 10:22
Neville Franks24-Sep-03 10:22 
GeneralGetCheck w listboxctrl (has checkboxes) Pin
ns24-Sep-03 9:52
ns24-Sep-03 9:52 
Which message do I need? I am trying NM_CLICK, and in that handler I check to see if any of my items is checked (have checkboxes). Problem is, the first item I click, triggers the event and the code steps into the function where I look for a checked item:

void CDlgFTP::OnClickLstftp(NMHDR* pNMHDR, LRESULT* pResult) 
{
	for( int index = 0; index <  m_lstFiles.GetItemCount(); index++)
	{
		BOOL chk = m_lstFiles.GetCheck(index);
		if (chk)
		{
		  	m_bGet.EnableWindow(TRUE);
		}

	}	
	*pResult = 0;
}


but this time around, chk is 0, but when I check the second item, and step into the code, the chk for element # 1 becomes 1, since its now checked. SO it looks like I am triggering my checkbox checking code prematurely. What message should I use instead?

Basically I want a button to get enabled when any item is selected in the listctrl.

Thanks,
ns
GeneralDialog menu problem... Pin
LukeV24-Sep-03 8:17
LukeV24-Sep-03 8:17 
GeneralRe: Dialog menu problem... Pin
David Crow24-Sep-03 8:22
David Crow24-Sep-03 8:22 
GeneralRe: Dialog menu problem... Pin
LukeV24-Sep-03 8:28
LukeV24-Sep-03 8:28 
GeneralRe: Dialog menu problem... Pin
RChin24-Sep-03 8:46
RChin24-Sep-03 8:46 
GeneralRe: Dialog menu problem... Pin
LukeV24-Sep-03 9:49
LukeV24-Sep-03 9:49 
GeneralNeed help with multi-dim arrays please Pin
Flack24-Sep-03 7:51
Flack24-Sep-03 7:51 
GeneralRe: Need help with multi-dim arrays please Pin
David Crow24-Sep-03 8:20
David Crow24-Sep-03 8:20 
GeneralRe: Need help with multi-dim arrays please Pin
Flack24-Sep-03 8:34
Flack24-Sep-03 8:34 
GeneralRe: Need help with multi-dim arrays please Pin
David Crow24-Sep-03 9:04
David Crow24-Sep-03 9:04 
GeneralRe: Need help with multi-dim arrays please Pin
JWood24-Sep-03 8:39
JWood24-Sep-03 8:39 
GeneralRe: Need help with multi-dim arrays please Pin
John M. Drescher24-Sep-03 15:08
John M. Drescher24-Sep-03 15:08 
QuestionMultiple lines in a static text control? Pin
b_girl24-Sep-03 7:23
b_girl24-Sep-03 7:23 
AnswerRe: Multiple lines in a static text control? Pin
Michael P Butler24-Sep-03 7:39
Michael P Butler24-Sep-03 7:39 
GeneralRe: Multiple lines in a static text control? Pin
b_girl24-Sep-03 7:49
b_girl24-Sep-03 7:49 
GeneralQuickie question re char buffers Pin
NewportKarl24-Sep-03 7:21
NewportKarl24-Sep-03 7:21 
GeneralRe: Quickie question re char buffers Pin
Ravi Bhavnani24-Sep-03 7:55
professionalRavi Bhavnani24-Sep-03 7:55 
GeneralRe: Quickie question re char buffers Pin
Alvaro Mendez24-Sep-03 9:07
Alvaro Mendez24-Sep-03 9:07 

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.